Lines Matching refs:statements
375 - The #include and #error statements are allowed to exceed the line length requirement. However, yo…
491 ### Rule 2.6 Use braces for conditional statements.
493 Use braces to enclose conditional statements, even if there is only one statement.
499 - Function-like macros without braces are used in conditional statements, can be error prone if bra…
529 ### Rule 2.8 Use braces for loop statements.
531 Use braces to enclose the `for` and `while` statements, even if there is only one loop.
622 ### Rule 2.10 Do not write multiple variable definitions or assignment statements in one line.
634 int maxCount = 10; bool isCompleted = false; // Bad: Multiple initialization statements are placed …
640 pointX = 1; pointY = 2; // Bad: Multiple variable assignment statements are placed in one line.
831 Loops and conditional statements:
1353 …gner's intention, using clean abstractions and straightforward control statements to organize the …
1373 …nction refers to the layered depth of a code control block (created by statements such as `if`, `f…
1379 Using `guard clauses` can effectively reduce the nesting layers of the `if` statements. Example:
1625 …n in the following example) similar to a function. It contains several statements to implement a s…
1645 - A macro has no independent scope. When it is used together with control flow statements, unexpect…
1649 - Macros containing a large number of statements must be expanded at each call point. If there are …
1701 …calculated when the macro is compiled. After the text replacement, the statements contained in the…
1767 …e="r6-2"></a>Rule 6.2 Place implementation statements of function-like macros that contain multipl…
1769 …ng code. As a result, variable name conflict and segmentation of macro statements may occur. Use `…
1787 To solve the preceding problem, use braces to enclose the statements defined by `FOO`.
1819 - Macros that contain 'break' or 'continue' statements can be treated as exceptions. Do use these m…
1850 ### Rec 6.2 Exercise caution when you use the statements such as `return`, `goto`, `continue`, and …
1852 Although process changing statements, such as `return`, `goto`, `continue`, and `break`, in a macro…
1902 In summary, it is not recommended to encapsulate process changing statements, such as `return`, `go…
1906 Note: **Macro names must contain descriptive keywords if process changing statements, such as `retu…
2163 …destroys the program. Avoid using it if possible. You can only jump to statements following the `g…