Updated July 2016; see History
ASB supports the data types shown in the tables below.
Scalar Types
Type |
Code |
Description |
---|---|---|
Floating Point |
F,4 |
32 bit IEEE float |
F,6 |
48 bit AMOS float |
|
F,8 |
64 bit IEEE float |
|
Binary, little endian |
B,1 |
8 bit unsigned |
B,2 |
16 bit unsigned |
|
B,3 |
24 bit unsigned |
|
B,4 |
32 bit unsigned |
|
B,5 |
40 bit signed (two's complement) |
|
B,6 |
||
I,6 |
||
Integer |
I,1 |
8 bit signed (two’s complement) |
I,2 |
16 bit signed (two’s complement, little-endian) |
|
I,4 |
32 bit signed (two’s complement, 2301 order) |
|
String |
S,# |
fixed length string of # bytes |
S,0 |
variable length string (dynamically sized, always with trailing null) |
|
Unformatted |
X,# |
fixed length raw bytes |
(none) |
May be declared implicitly by leaving type,size specifier in MAP statement blank and defining lower-level MAP Statements. |
Compound or Structure Types
Type |
Example |
See Note # |
---|---|---|
Multi-level MAPs |
MAP1 CUST READ #CH, CUST ! read/write entire group as a unit ? NAME ! individual fields referenced by name |
1, 2 |
DEFSTRUCT ST_CUST ! define structure layout |
|
|
MAP1 DS, DYNSTRUCT |
|
Table Notes:
1 | Also known as "records", the multi-level MAP arrangement is physically equivalent a DEFSTRUCT, except for the syntax of accessing its members. Programmers are encouraged to use DEFSTRUCT as it makes the code more self-documenting and simplifies creating multiple instances and arrays of the layout. |
2 | Any MAPn level with higher-numbered levels defined within it |
See Also
History
2016 June, A-Shell 6.3.1516, compiler edit 763: Added variable types B6 and I6. See following topic.
Subtopics