Update CODING-GUIDELINES
This commit is contained in:
parent
389ef31a8f
commit
088ef4f6f9
|
@ -24,7 +24,7 @@ For POD-types, try to order structs as follows (first to last):
|
||||||
* enum (4 bytes)
|
* enum (4 bytes)
|
||||||
* int16_t (2 bytes)
|
* int16_t (2 bytes)
|
||||||
* char (1 byte)
|
* char (1 byte)
|
||||||
* bool (1 byte)
|
* bool (1 byte)
|
||||||
|
|
||||||
[1] PS3 uses 4 byte pointers despite having a 64bit processor
|
[1] PS3 uses 4 byte pointers despite having a 64bit processor
|
||||||
|
|
||||||
|
@ -107,3 +107,8 @@ VLA (Variable Length Array)
|
||||||
---------------------------
|
---------------------------
|
||||||
Do not use VLAs (Variable Length Array) in C source files. These are not
|
Do not use VLAs (Variable Length Array) in C source files. These are not
|
||||||
C89-compliant.
|
C89-compliant.
|
||||||
|
|
||||||
|
Miscellaneous
|
||||||
|
-------------
|
||||||
|
- A single statement block must not include brackets (unless the block uses a macro that expends into multiple lines)
|
||||||
|
- If possible, avoid 'while (true)' and use 'for (;;)' instead
|
||||||
|
|
Loading…
Reference in New Issue