[fpc-devel] Generic List in Advanded record does not compile with -MobjFPC, works with -MDelphi (perhaps related to Generics.Collections that I am using)

Michael Ring mail at michael-ring.org
Mon Apr 27 20:19:54 CEST 2015


I am not sure if this is a problem of the Generics.Collections unit I am 
using (https://github.com/dathox/generics.collections) as this unit is 
always compiled with -Mdelphi or if this is an issue with fpc's parser.

The following snippet compiles fine in delphi mode, but does not compile 
in ObjectFPC Mode:

type
   TSpecialFunctionBits = record
     name: String;
     Position: longWord;
     Mask: longWord;
     notMask: longWord;
     Length: longWord;
     constructor create(theName: String; thePosition, theMask, 
theLength: longWord);
   end;

Error is:

Fatal: Syntax error, ";" expected but "<" found

I saw this error with trunk fpc.

Michael





More information about the fpc-devel mailing list