I typed to soon.
The code:
unit MemoryBlock;
{$IFDEF FPC}
//{$mode delphi}
{$MODE OBJFPC}
{$ENDIF}
interface
uses
Classes;
type
TMemoryBlock = packed record
Identifier: LongInt;
Block: Pointer;
Size: LongInt;
Lock: Boolean;
State: Byte;
Pad1, Pad2: Byte;
constructor Create(nbytes: Integer); // lazarus issue
end;
got
MemoryBlock.pas(25,5) Fatal: Syntax error, "END" expected but "CONSTRUCTOR" found
in objfppc
MemoryBlock.pas(25,5) Error: Constructors aren't allowed in records or record helpers
in delphi
So do you have a magic setting for the compile environment?
sarason