HLASM Language Reference
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Macro instruction

HLASM Language Reference
SC26-4940-06

A macro instruction is a source program statement that you code to tell the assembler to process a particular macro definition. The assembler generates a sequence of assembler language statements for each occurrence of the same macro instruction. The generated statements are then processed as any other assembler language statement.

The macro instruction provides the assembler with:
  • The name of the macro definition to be processed.
  • The information or values to be passed to the macro definition. The assembler uses the information either in processing the macro definition or for substituting values into a model statement in the definition.
The output from a macro definition, called by a macro instruction, can be:
  • A sequence of statements generated from the model statements of the macro for further processing at assembly time.
  • Values assigned to global SET symbols. These values can be used in other macro definitions and in open code.

You can call a macro definition by specifying a macro instruction anywhere in a source module. You can also call a macro definition from within another macro definition. This type of call is an inner macro call; it is said to be nested in the macro definition.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014