Newbie Question - memory overlays
Jacques Collin
zerozerosix at hotmail.com
Mon Oct 23 10:27:42 PDT 2006
I union would not fit the job.
In Delphi, I can have, for example,
-- fdata1 : file of infonode
-- datastore : array[1..n] of infonode;
-- ctrlpoint : array[1..100] of infonode absolute datastore[1]
where
the first 100 "infonodes" can be used as an array. And the rest of
the "datastore" can be used as a list or even a tree.
at some point the "datstore" will be written out to disk.
I would prefer to avoid a cumbersome work-around like a union
(a.k.a variant records) in favour of the elegant Delphi solution
of simply using the "absolute" attribute.
Any suggestions?
Thanks
More information about the Digitalmars-d
mailing list