Go to the first, previous, next, last section, table of contents.


5.2.1 Constants and Variables

Constants created using #define should be all upper case. Macros created using #define should be either initial letter upper case or all lower case (to allow replacement by procedures) when they take arguments. Global variables should be first character upper case. Procedures and all local variables should be all lower case.

Compound names are formed with underscore separators, eg., CONSTANT, nifty_macro(), Global_Variable, local_variable.

Don't reuse variable names. A single variable name should have a single meaning in the widest possible scope (minimally within the body of a procedure, preferably within an entire library). Iteration variables should always iterate over the same domain.


Go to the first, previous, next, last section, table of contents.