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

Category: Control flow

Synopsis:Control flow


Description:

Coding Rules

NameCheckedSynopsis
6@101 Checked automatically with code checker Do not change a loop variable inside a for loop block
6@102 Update loop variables close to where the loop condition is specified
6@103 Checked automatically with code checker All flow control primitives (if, else, while, for, do, switch) shall be followed by a block, even if it is empty
6@105 Checked automatically with code checker All switch statements shall have a default label as the last case label
6@106 Checked automatically with code checker Finish every if-else-if statement with an else part
6@109 Checked automatically with code checker Avoid multiple or conditional return statements
6@112 Checked automatically with code checker Do not make explicit comparisons to true or false
6@115 Checked automatically with code checker Do not access a modified object more than once in an expression
6@118 Do not use selection statements (if, switch) instead of a simple assignment or initialization
6@119 Avoid locking on a public type
6@120 Avoid conditions with double negatives
6@121 Don't use parameters as temporary variables
6@191 Checked automatically with code checker Do not dereference null
6@201 Checked automatically with code checker The cyclomatic complexity of a method should not exceed its configured maximum.