Chapter 10 Writing Assembler Control Statements

10.4.3 #ifeq, #ifneq

Syntax

Syntax for #ifeq

Syntax for #ifneq

#ifeq

parameter1, parameter2

#ifneq

parameter1, parameter2

 

block1

 

block1

[#else

block2]

[#else

block2]

 

 

#endif

 

#endif

 

Functional description

#ifeq

If parameter1 and parameter2 are the same string, block1 will be assembled. If they are different and an #else directive has been coded, block2 will be assembled.

#ifneq

If parameter1 and parameter2 are different strings, block1 will be assembled. If they are the same and an #else directive has been coded, block2 will be assembled.

Coding rules

These directives can only be used within macro definitions.

Either or both of parameter1 and parameter2 may be dummy parameters set up during macro definition.

Conditional Assembly 195

Page 207
Image 207
Panasonic MN1030 user manual 10.4.3 #ifeq, #ifneq