[fpc-pascal] Helper type and class fields
silvioprog
silvioprog at gmail.com
Mon Dec 1 21:04:52 CET 2014
On Mon, Dec 1, 2014 at 4:49 PM, Sven Barth <pascaldragon at googlemail.com>
wrote:
> Am 01.12.2014 18:59 schrieb "silvioprog" <silvioprog at gmail.com>:
> >
> > Hello,
> >
> > From the Embarcadero wiki:
> >
> > "A helper type may not declare instance data, but class fields are
> allowed." (
> http://docwiki.embarcadero.com/RADStudio/XE7/en/Class_and_Record_Helpers_(Delphi)
> ).
> >
> > In Delphi it compiles fine:
> >
> > TFoo = class
> > end;
> >
> > TBar = class helper for TFoo
> > private class var
> > FFoo: TFoo;
> > end;
> >
> > In FPC:
> >
> > project1.lpr(11,5) Error: An interface, helper or Objective-C protocol
> or category cannot contain fields
> >
> > Bug?
>
> Yes, bug. Please report.
>
> Regards,
> Sven
>
Done: http://bugs.freepascal.org/view.php?id=27120.
Thx!
--
Silvio Clécio
My public projects - github.com/silvioprog
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20141201/e4d3213d/attachment.html>
More information about the fpc-pascal
mailing list