Search code examples
c++coding-styleboilerplatecomments

What exactly is license boilerplate commenting and what format does it need to be in?


I was reading through the Google C++ Style Guide to try to emulate good coding practices. When I read through the section on how to comment my code, it asks me to start each file with license boilerplate. All I could find out about this terminology was from Mozilla and what I believe to be their commenting standards. What exactly is license boilerplate commenting and what format does it need to be in?

Note: To be clear, I'm not saying the Google C++ Style Guide is the perfect guide to follow for good coding practices. I'm just using it to gain new ideas on how to better my coding style.


Solution

  • "License boilerplate" is a comment block placed at the beginning of each source code file that describes or names the license or terms that the source code has been placed under. If there is a specific commenting style that is required to use then the license itself will describe it, otherwise one is free to use any style they like.