Table of Contents
Previous topic Next topic
ASSEMBLER DIRECTIVES->Other Assembler Directives->IFC/IFNC/IFIC/IFINC
IFC/IFNC/IFIC/IFINC Conditional Assembly with String Comparison
These directives cause the assembly of the subsequent block of statements to be dependant upon the comparison of two character strings in the operand. The ENDC directive marks the end of the statement block.
|IFC||<string 1>,<string 2>||<comment> |
|IFNC||<string 1>,<string 2>||<comment> |
|IFIC||<string 1>,<string 2>||<comment> |
|IFINC||<string 1>,<string 2>||<comment> |
The statements following IFC and IFIC will be assembled if string 1 and string 2 are the same. The statements following IFNC and IFINC will be assembled if string 1 and string 2 are different. IFC and IFNC perform a case sensitive comparison on the two strings whereas IFIC and IFINC perform a case insensitive comparison.
These directives are usually used in macro definitions where either one or both of the strings is a macro argument. The directives can then be used to generate different object code depending on the string or strings passed in the argument or arguments.
These conditional assembly directives can be nested.