Attributes of symbols and expressions
Yes) or not (
No) you can validly apply the attribute reference to that symbol type, or (for SET symbols) to the value of the symbol.
Symbols Specified | Type T' |
Length L' |
Scale S' |
Integer I' |
Count K' |
Number N' |
Defined D' |
Operation Code O' |
|
---|---|---|---|---|---|---|---|---|---|
In open code: | |||||||||
Ordinary symbols | Yes | Yes | Yes | Yes | No | No | Yes | Yes | |
System variable symbols with global scope | Yes | No | No | No | Yes | Yes | No | No | |
Literals in macro instruction operands | Yes | Yes | Yes | Yes | No | No | Yes | No | |
In macro definitions: | |||||||||
Ordinary symbols | Yes | Yes | Yes | Yes | No | No | Yes | Yes | |
Symbolic parameters | Yes | Yes | Yes | Yes | Yes | Yes | Yes | Yes | |
System variable symbols: | |||||||||
&SYSLIST | Yes | Yes | Yes | Yes | Yes | Yes | Yes | No | |
All others | Yes | No | No | No | Yes | Yes | No | No | |
Literals in macro instruction operands | Yes | Yes | Yes | Yes | No | No | Yes | No |
Symbols Specified | Type T' |
Length L' |
Scale S' |
Integer I' |
Count K' |
Number N' |
Defined D' |
Operation Code O' |
---|---|---|---|---|---|---|---|---|
In open code:
SET symbols |
SETB¹,
SETC |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETB¹,
SETC |
In ordinary assembly: | Yes | Yes | Yes | Yes | No | No | No | Yes |
In macro
definitions: SET symbols |
SETB¹,
SETC |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETA,
SETB² |
SETB¹,
SETC |
Notes:
|
The value of an attribute for an ordinary symbol specified in an attribute reference comes from the item named by the symbol. The symbol must appear in the name field of an assembler or machine instruction, or in the operand field of an EXTRN or WXTRN instruction.
- You cannot refer to the names of instructions generated by conditional assembly substitution or macro generation until the instruction is generated.
- If you use a symbol qualifier to qualify an ordinary symbol in an attribute reference, the qualifier is ignored.
The value of an attribute for a variable symbol specified in an attribute reference comes from the value substituted for the variable symbol as follows:
- SET Symbols and System Variable Symbols
- For SET symbols and all system variable symbols other than &SYSLIST, the attribute values come from the current value of these symbols.
- Symbolic Parameters and &SYSLIST
- For symbolic parameters and the system variable symbol, &SYSLIST,
the values of the count and number attributes come from the operands
of macro instructions. The name field entry of the call is an
operand
, and is referenced as &SYSLIST(0). The values of the type, length, scale, and integer attributes, however, come from the values represented by the macro instruction operands, as follows:- If the operand is a sublist, the entire sublist and each entry of the sublist can possess attributes. The whole sublist has the same attributes as those of the first suboperand in the sublist (except for the count attribute, which can be different, and the number attribute which is relevant only for the whole sublist).
- If the first character or characters of the operand (or sublist entry) constitute an ordinary symbol, and this symbol is followed by either an arithmetic operator (+, -, *, or /), a left parenthesis, a comma, or a space, then the value of the attributes for the operand are the same as for the ordinary symbol.
- If the operand (or sublist entry) is a character string other than a sublist or the character string described in the previous point, the type attribute is undefined (U) and the length, scale, and integer attributes are invalid.
Because the count (K'), number (N'), and defined (D') attribute references are allowed only in conditional assembly instructions, their values are available only during conditional assembly processing. They are not available at ordinary assembly time.
The system variable symbol &SYSLIST, with a valid subscript, can be used in an attribute reference to refer to a macro instruction operand, and, in turn, to an ordinary symbol. Thus, any of the attribute values for macro instruction operands and ordinary symbols in the following subtopics can also be substituted for an attribute reference containing &SYSLIST (see &SYSLIST System Variable Symbol).