marcov@stack.nl wrote:
In gmane.comp.compilers.gpc, you wrote:
What facilities does GPC have for forward defining types.
In CW Pascal, I have some code that looks like this:
[...]
MyObjectB = object; f: MyObjectA; // other references to ObjectA end;
(btw Does this compile? Note the semi-colon after object)
Yes, the semicolon seems wrong (at least in other dialects).
Delphi supports this: (remember its object model is similar)
Type MyObjectB = class; MyObjectA = class;
This seems to be what `class .. end' is in OOE.
Must be in one typeblock though, IOW, the same system as pointers.
Yes, same in OOE.
Frank