HP Pascal/iX Programmer's Guide (31502-90023)
5-: 6
| | | |
-------------------------------------------------------------------------------
| | | |
| Pointer | 4 bytes | 4-byte |
| | | |
-------------------------------------------------------------------------------
| | | |
| Procedure | 8 bytes | 4-byte |
| | | |
-------------------------------------------------------------------------------
| | | |
| Real | 4 bytes | 4-byte |
| | | |
-------------------------------------------------------------------------------
Table 5-2. Allocation and Alignment of Packed Variables
(HP Pascal Packing Algorithm) (cont.)
-------------------------------------------------------------------------------
| | | |
| Variable Type | Allocation | Alignment |
| | | |
-------------------------------------------------------------------------------
| | |
| Record | See "Records" for information on entire record |
| | and "Packed Records" for information on fields. |
| | |
-------------------------------------------------------------------------------
| | |
| Set | See "Sets" |
| | |
-------------------------------------------------------------------------------
| | | |
| Shortint | 2 bytes | 2-byte |
| | | |
-------------------------------------------------------------------------------
| | | |
| String | See "Strings" | 4-byte |
| | | |
-------------------------------------------------------------------------------
| | |
| Subrange | See "Enumerations and Subranges" . |
| | |
-------------------------------------------------------------------------------
Arrays
Arrays are stored in
row-major order
. This means that an array is stored
a row at a time, rather than a column at a time (
column-major order
).
Example
VAR
a : ARRAY [1..2,1..3] OF char;
Row-major order: