Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
fpc-src / usr / share / fpcsrc / 3.2.0 / tests / webtbs / tw25602.pp
Size: Mime:
{$MODE DELPHI}

type
  TA = class
    const C = 1;
  end;

  TB<T> = object
    procedure Foo;
  end;

procedure TB<T>.Foo;
var
  // X: array[0..T.C] of byte = (0); // Error: Expected another 1 array elements
  X: array[0..T.C] of byte = (0, 2); // Fatal: Syntax error, ")" expected but "," found
begin
  if high(x)<>1 then
    halt(1);
  writeln('ok');
end;

var
  x: TB<TA>;
begin
  x.Foo;
end.