_COSYMB Conditional Symbols Report

Top  Previous  Next

 

[BP7,D1,D2,D3,D4,D5,D6,D7,D8, D2005W, D2005N, D2006W, D2006N, D2007W]

 

This report has different sections presenting information about conditional symbols.

 

Conditional symbols that were defined ($DEFINE) in code

This is a list of all conditional symbols that were defined in the parsed code. Use this list for a sanity-check that your code defines the correct symbols. This section also reports symbols that are defined in code that is excluded for reporting.

 

 

Conditional symbols that were undefined ($UNDEF) in code

This is a list of all conditional symbols that were undefined in the parsed code. Use this list for a sanity-check that your code defines the correct symbols. This section also reports symbols that are defined in code that is excluded for reporting.

 

 

Conditional symbols/expressions that were evaluated as true ($IF/$IFDEF/$ELSEIF)

This is a list of all conditional symbols or expressions that at some point in the code were evaluated as true.

 

 

Conditional symbols/expressions that were evaluated as false ($IF/$IFDEF/$ELSEIF)

This is a list of all conditional symbols or expressions that at some point in the code were evaluated as false.

 

 

Unnecessary $DEFINE/$UNDEF

This section lists locations in the source code where a $DEFINE or $UNDEF directive is repeated unnecessarily. The directive can normally be removed from the location where it is repeated, giving code that is easier to comprehend and maintain.

 

Example

 

..

(*$DEFINE Final*)

var

X : integer;

Y : integer;

 

(*$DEFINE Final*) <-- unnecessary, Final is already defined

const

sAppName = 'AppName'; 

(*$ENDIF*)

..

(*$ENDIF*)

 

 

Unnecessary $IFDEF/$IFNDEF

This section lists locations in the source code where a $IFDEF or $IFNDEF directive is repeated unnecessarily. The directive can normally be removed from the location where it is repeated, giving code that is easier to comprehend and maintain.

 

Example

 

..

(*$IFDEF Special*)

var

X : integer;

Y : integer;

 

(*$IFDEF Special*) // <-- this directive is unnecessary

S : string;

(*$ENDIF*)

 

(*$ENDIF*)

..

 

$DEFINE/IFDEF used but no matching $IFDEF/$IFNDEF in code

This section lists conditional symbols that were defined ($DEFINE/IFDEF) either in code, or by options, but are not referenced ($IFDEF/$IFNDEF) in the code. Those conditional symbols are probably unnecessary and can be removed.

 

See also:

 

R_REF Reference Reports