pascalabcnet/TestSuite/lambdas23.pas

21 lines
265 B
ObjectPascal
Raw Permalink Normal View History

2024-03-26 23:49:51 +03:00
var j := 0;
type
t1 = class
static property prop1: integer read 1;
static constructor;
begin
var p := ()->
begin
j := prop1;
end;
p;
end;
end;
begin
var i := t1.prop1;
assert(j = 1);
end.