4.5. Storage Allocation

Computer storage space for data is allocated automatically at compile time, one word for each simple reference, one for each array element, and as many as are declared for each table entry. In any one composite declaration, a Coral 66 compiler is explicitly required to perform allocation serially. For example, the declarations

INTEGER a, b, c;

will make the locations of a, b, c become n, n+1, n+2 respectively, and those of p, q become m, m+1 where n and m are undefined and unrelated. In two-dimensional arrays, the second index is stepped first: the declaration

INTEGER ARRAY a[1:2], b[1:2, 1:2];

will locate the elements

a[1], a[2], b[1,1], b[1,2], b[2,1], b[2,2]

in consecutive ascending locations.