C++ style guide: Difference between revisions

384 bytes added ,  30 August 2021
m
New naming recommendations
m (Add guideline for member variables)
m (New naming recommendations)
Line 142: Line 142:


Member variables should use the prefix "m_" whenever possible.
Member variables should use the prefix "m_" whenever possible.
==== Class Variables ====
Class variables should use the prefix "s_" (for "static") whenever possible.
==== Filenames ====
As with m-files, the file name of a C++ source file containing a class should match the name of the class defined within the file.  For example, "password.h" defines the class "password" rather than "passwd.h" which is a common abbreviation for "password".


== Header Files ==
== Header Files ==
1,072

edits