Am 04.03.2013 01:15, schrieb Graeme Geldenhuys:
> [...]
It was clearly stated in the past that FPC will not support the C/C++
language feature of declaration a variable in-line inside code blocks,
but only in var sections.
Example of not allowed code:
for i: integer = 0 to 10 do
begin
end;
> [...]
From what I can see, anonymous methods are just like the above code...
No, inside declaration is not anonymous, the declared var has a name.
Look at this:
with TObject.Create do begin
WriteLn(ToString);
Free;
end;
That is anonymous, and it works in Object-Pascal.
On the other hand I am not sure if anonymous are a good idea, even if I
like them while working in VB.NET.
But please: if they are coming, don't implement them in the bad way of
Delphi.
Michael
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel