I want to create an array of records and have it be a typed constant, I've tried the following:
The compiler gives "Field Identifier Expected" at the first quote. Can something like this be done?
Code:
Type
ElementType = record
Noun : String ;
AtomNum : Byte ;
AtomMass : Real
end ;
Const
ATOM_TABLE : Array [0 .. 2] of ElementType =
(
('Hydrogen', 1, 1.00794),
('Helium', 2, 4.002602),
('Lithium', 3, 6.941)
)
The compiler gives "Field Identifier Expected" at the first quote. Can something like this be done?