The Code is Documentation Enough
Tina Ulbrich
„The compiler does not read comments, and neither do I” - Bjarne Stroustrup
Comments have a lot of downsides. Not only does the compiler not read them, most developers don’t either. So, comments have the tendency to get out of sync with the code quickly. The solution seems to not write comments at all. Self-documenting code is the goal for many developers. But how can we actually achieve this? Are there instances where it’s simply not possible? In this talk, I want to share different techniques to increase the likelihood of self-documented code. We will look into how to name variables and functions, how language features can increase readability and how unit tests can serve as documentation of how the code should be used. Lastly, we are going to explore instances of where a comment is useful and how to write a good one.
Tina Ulbrich
Tina works at ROSEN, a service provider in the oil and gas industry. She writes and maintains numerical and data processing algorithms for pipeline inspection data. She highly values simple, modern and clean code, using the latest language features. She promotes refactoring, high test coverage and collaboration between developers. Tina holds a university degree in Bio-Mathematics from the University of Applied Science in Zittau/Görlitz. She is a member of the #include Discord community.