I am currently converting an OpenVMS DEC-PASCAL model into GPC
(v.19991030 based on 2.95.2 19991024) on a LINUX PC.
Part of this task is to, where ever possible, maintain a common source
between the two systems. The model initialises many variables using the
DEC-PASCAL function "ZERO", is there an equivalent within GPC that works
with any variable, or record, type.
VAR
i : INTEGER;
r : REAL;
d : ARRAY[1..5] OF DOUBLE;
BEGIN
i := zero;
r := zero;
d := zero;
END.
I've searched the documentation but cannot find anything, the closest
I've come is to pass an untyped parameter and its size to a function,
then use pointers to set the memory to zero (0x00). This works OK for
GPC, but DEC-PASCAL doesn't seem to like untyped parameters.
Any help would be appreciated, as would any comments from people who
have undertaken a similar task.
Thanks, in advance
Lee.
--
The Information contained in this E-Mail and any subsequent correspondence
is private and is intended solely for the intended recipient(s).
For those other than the recipient any disclosure, copying, distribution,
or any action taken or omitted to be taken in reliance on such information is
prohibited and may be unlawful.