Merge pull request #5387 from leoetlino/constexpr
Contributing: Use constexpr for compile-time constants
This commit is contained in:
commit
7a25dde8df
|
@ -89,8 +89,8 @@ Summary:
|
|||
- `class SomeClassName`
|
||||
- `enum IPCCommandType`
|
||||
- All compile time constants should be fully uppercased. With constants that have more than one word in them, use an underscore to separate them.
|
||||
- `const double PI = 3.14159;`
|
||||
- `const int MAX_PATH = 260;`
|
||||
- `constexpr double PI = 3.14159;`
|
||||
- `constexpr int MAX_PATH = 260;`
|
||||
- All variables should be lowercase with underscores separating the individual words in the name.
|
||||
- `int this_variable_name;`
|
||||
- Please do not use [Hungarian notation](http://en.wikipedia.org/wiki/Hungarian_notation) prefixes with variables. The only exceptions to this are the variable prefixes below.
|
||||
|
|
Loading…
Reference in New Issue