type-inquiry

Paul Isaacs <[email protected]> Sat, 21 Jan 2017 15:19:35 -0500
Newsgroups gmane.comp.compilers.gpc
Message-ID <[email protected]>
Hello,

How is the production type-inquiry used?

var
p : integer;

type
q = type of p;

How would it be possible that inquiring as to the type of p is useful? 
Under what circumstances would the type of p not be already known?

Even if the type of p were not known, how would q be usable if its type 
were not fixed?

The only reference I can find is in the GNU-Pascal Manual.

function CompilerAssert( condition : boolean, result : Anytype ) : type 
of Anytype;

What would be returned? Unless Anytype is restricted to types that 
CompilerAssert is aware of.

Regards,

Paul Isaacs


_______________________________________________
Gpc mailing list
[email protected]
https://www.g-n-u.de/mailman/listinfo/gpc