fpc/tests/webtbs/tw10795.pp
2008-05-18 13:27:59 +00:00

18 lines
292 B
ObjectPascal

{$mode objfpc}
type
TObj = object
function GetItem(const i :Integer) :Integer;
property Items[i :Integer] :Integer read GetItem; default;
end;
function TObj.GetItem(const i :Integer) :Integer;
begin
Result := i;
end;
var
Obj :TObj;
begin
WriteLn(Obj[0],' ',Obj[10]);
end.