Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2021-04

Generic class aliases

2 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Ryan Joseph

With normal classes you can make aliases to other units but with generics you get an error. Am I doing this wrong or is this not supported?

type
  TList = UOther.TList;  // Generics without specialization cannot be used as a type for a variable

Regards,
Ryan Joseph

Reply by email

Sven Barth
to Ryan Joseph

Ryan Joseph via fpc-pascal schrieb am
Fr., 16. Apr. 2021, 18:29:

Show quoted text 6 lines
With normal classes you can make aliases to other units but with generics you get an error. Am I doing this wrong or is this not supported? type TList = UOther.TList; // Generics without specialization cannot be used as a type for a variable

This is not supported.

Regards,
Sven

Reply by email