|
Table 1 shows attribute references
(in the columns) and types of symbols (in the rows). Each intersection
shows whether ("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.
Table 1. Attributes and related
symbolsSymbols
Specified
|
Type
T'
|
Length
L'
|
Scale
S'
|
Integer
I'
|
Count
K'
|
Number
N'
|
Defined
D'
|
Operation
Code
O'
|
---|
In open code:
Ordinary
symbols
System variable
symbols with
global scope
Literals in
macro
instruction
operands
|
Yes
Yes
Yes
|
Yes
No
Yes
|
Yes
No
Yes
|
Yes
No
Yes
|
No
Yes
No
|
No
Yes
No
|
Yes
No
Yes
|
No
No
No
|
In macro
definitions:
Ordinary
symbols
Symbolic
parameters
System variable
symbols:
&SYSLIST
All others
Literals in
macro instruction
operands
|
Yes
Yes
Yes
Yes
Yes
|
Yes
Yes
Yes
No
Yes
|
Yes
Yes
Yes
No
Yes
|
Yes
Yes
Yes
No
Yes
|
No
Yes
Yes
Yes
No
|
No
Yes
Yes
Yes
No
|
Yes
Yes
Yes
No
Yes
|
No
Yes
No
No
No
|
The values of attribute references can be used in ordinary and
conditional assembly expressions, as shown in Table 2.
Table 2. Using attribute
valuesSymbols
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: |
No |
Yes |
Yes |
Yes |
No |
No |
No |
No |
In macro
definitions:
SET symbols
|
SETB¹,
SETC
|
SETA,
SETB²
|
SETA,
SETB²
|
SETA,
SETB²
|
SETA,
SETB²
|
SETA,
SETB²
|
SETA,
SETB²
|
SETB¹,
SETC
|
Notes: - Only in character relations.
- Only in arithmetic relations.
|
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.
The value of an attribute reference to an expression is the value
of that attribute reference to its leftmost term. Notes: - 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).
|