TList of interface compilation error

Hi,

If I do the following:

type
  IMyInterface=interface(IInterface)
end;

...

begin
var
  MyList:TList<IMyInterface>.create;
end;

I simply get an 'error during compilation' message, with no specifics.

Thanks!

This is sadly an issue of the pas2js transpiler.
We'll report this issue to the pas2js team.

Closest workaround for now:

var
  myList: TList<TInterfacedPersistent>;
begin
  MyList := TList<TInterfacedPersistent>.Create;
  try
    // use MyList here
  finally
    MyList.Free;
  end;
end;

Ah, no worries.

Thanks!