TICS Coding Standard Viewer 
TIOBE Software Quality Framework
Print-friendly version
©TIOBE Software www.tiobe.com
 
TIOBE - C Coding Standard
Search

Guideline:  12.3#5Checked automatically with code checker

This rule is Obsolete
Synopsis:Macros should behave like symbolic constants or functions, (as function-like macros).
Language:C
Severity Level:5
Category:PREPROCESSING


Description:
Macro definitions should not therefore contain '{', '}', ';' or keywords.

Example:

#define foreach(e, c) \\\\
    S* _iter ## e; \\\\
    for (_iter ## e = c; _iter ## e != NULL && ((e = _iter ## e -> val) || 1); _iter ##e = _iter ## e ->next)