Name | Checked | Synopsis |
---|
ORG#001
|
 |
Enclose all code in header files within include guards |
ORG#002
|
|
Each file shall be self-contained |
ORG#003
|
 |
From a source file include only header files |
ORG#004
|
|
Classes that are only accessed via pointers (*) or references (&) shall not be included as header files |
ORG#005
|
|
Each file shall directly include each header file upon which declarations it directly depends |
ORG#006
|
 |
C++ header files have the extension .h, .hpp or .hxx |
ORG#007
|
 |
C++ source files have the extension .cpp |
ORG#008
|
|
Place non-portable code in a special file so that it may be easily located when porting code from one architecture/environment to another |
ORG#009
|
|
Avoid unnecessary inclusion |
ORG#010
|
 |
Do not let assertions change the state of the program |
ORG#011
|
 |
Everything must reside in a namespace |
ORG#012
|
 |
Never put "using namespace" in header files |
ORG#013
|
 |
Don't put definitions in header files |