[fpc-pascal] Name collisions in scoped enums

Ryan Joseph genericptr at gmail.com
Mon May 4 05:06:15 CEST 2020


I've been using scoped enums and noticed that I'm getting collisions with reserved keywords. Shouldn't these be allowed in scoped enums since they are required to be referenced using their type name as a prefix? 


{$mode objfpc}

program test;

{$scopedenums on}

// error: Syntax error, "identifier" expected but "FILE" found
type
  TSet = set of ( File, Array );

begin

end.

Regards,
	Ryan Joseph



More information about the fpc-pascal mailing list