Delphi Compiler Error
E2564 Undefined type ‘%s’
Reason for the Error & Solution
This occurs when trying to define a type restraint on a generic type using itself.
program E2564;
{$APPTYPE CONSOLE}
type
TRec<T: record> = record
A: T;
end;
TClass = record
V: TRec<TClass>; //E2564
end;
begin
end.