Operation code attribute (O')
The operation code attribute shows whether a given operation code has been defined prior to the attribute reference. The operation code can be represented by a character string or by a variable symbol containing a character string. The variable must be set using a SETC assembler instruction prior to being referenced by the operation code (O') attribute.
The operation code attribute has a value of a single alphabetic character that shows the type of operation represented.
This attribute reference can be used in the operand field of the SETC instruction or as one of the values used in the operand field of a SETB or AIF instruction.
- A refers to assembler operation code.
- E refers to extended mnemonic operation code.
- M refers to macro definition.
- O refers to machine operation code.
- S refers to macro definition found in library.
- U refers to undefined, unknown, unassigned, or deleted operation code.
- The assembler does not enter lookahead mode to resolve the operation code type, therefore only operation codes defined at the time the attribute is referenced return an operation code type value other than U.
- When the operation code is not an assembler instruction or a machine instruction, and the operation code is not a previously defined macro, then all libraries in the library data set definition list are searched. This might have an adverse impact on the performance of the assembly, depending on the number of libraries assigned in the assembly job and the number of times the operation code attribute is used.
Name Operation Operand
&A SETC O'MVC
&A
contains the letter O
,
because MVC is a machine operation code: Name Operation Operand
&A SETC 'DROP'
&B SETC O'&A
&B
contains the letter A
,
because DROP is an assembler operation code.
Name Operation Operand
&CHECKIT SETC O'MAC1
AIF ('&CHECKIT' EQ 'U').NOMAC
MAC1
.NOMAC ANOP
.
Redefined Operation Codes: If an operation code is redefined using the OPSYN instruction then the value returned by a subsequent operation code attribute reference represents the new operation code. If the operation code is deleted using the OPSYN instruction then the value returned is U.