[Lazarus] Declare record variant in it self

Michael Van Canneyt michael at freepascal.org
Thu May 7 13:05:55 CEST 2015



On Thu, 7 May 2015, aradeonas wrote:

> Thanks Michael.
>
> Is there a way so I can use class with no need of create and destroy?So
> in this way I can even make simple functions in my class.

You can use Objects. 
But you will need the same trick as for records, using a pointer.

Your definition is recursive.
There is no recursive definition in Pascal.

Mattias' proposal is the best you can do.

Michael.




More information about the Lazarus mailing list