[fpc-devel] Abbrevia and Delphi compatibility
Marco van de Voort
marcov at stack.nl
Wed Feb 16 13:32:54 CET 2005
> D6 accepts:
>
> type x = object
> fblaat : integer;
> property blaat:integer read fblaat write fblaat;
> end;
>
> assignig fblaat and writeln(blaat) also works.
>
> So it seems it works as expected in D6.
Same with FPC, the below program prints 1234 (recent 1.9.7):
{$mode delphi}
type x = object
fblaat : integer;
procedure fillblaat;
property blaat:integer read fblaat write fblaat;
end;
procedure x.fillblaat;
begin
fblaat:=1234; // this 1234 is printed.
end;
var y:x;
begin
y.fblaat:=1234;
y.fillblaat; // this can be omitted and it still works
writeln(y.blaat);
end.
More information about the fpc-devel
mailing list