UNSPEC returns a bit string that is the internal coded form of x.
>>-UNSPEC(x)---------------------------------------------------><
The length of the returned bit string depends on the attributes of x, as shown in Table 1.
Bit string length | Attribute of x |
---|---|
8 | SIGNED FIXED BINARY(p,q), 1 <= p <= 7 |
16 | SIGNED FIXED BINARY(p,q), 8 <= p <= 15 |
32 | ENTRY LIMITED, under LP(32) |
64 | ENTRY LIMITED, under LP(64) |
128 | FLOAT BINARY(p), 54 <= p |
n | BIT(n) |
8*n | CHARACTER(n)PICTURE (with character-string-value length of n) |
16*n | GRAPHIC(n)WIDECHAR(n) |
16+n | BIT(n) VARYING where n is the maximum length of x |
32+n | BIT(n) VARYING4 where n is the maximum length of x |
16+(8*n) | CHARACTER(n) VARYING where n is the maximum length of x |
32+(8*n) | CHARACTER(n) VARYING4 where n is the maximum length of x |
8+(8*n) | CHARACTER(n) VARYINGZ where n is the maximum length of x |
16+(16*n) | GRAPHIC(n) VARYING where n is the maximum length of x WIDECHAR(n) VARYING where n is the maximum length of x |
32+(16*n) | GRAPHIC(n) VARYING4 where n is the maximum length of x WIDECHAR(n) VARYING4 where n is the maximum length of x |
16+(16*n) | GRAPHIC(n) VARYINGZ where n is the maximum length of x WIDECHAR(n) VARYINGZ where n is the maximum length of x |
8*(n+16) | AREA (n) under LP(32) |
8*(n+32) | AREA (n) under LP(64) |
8*FLOOR(n) | FIXED DECIMAL (p,q) where n = (p+2)/2 |
Alignment and storage requirements for program-control data can vary across supported systems.
If x is a VARYING or VARYING4 string, its length prefix is included in the returned bit string. If x is an area, the returned value includes the control information.