Add final and sealed as class options

This commit is contained in:
Ricardo Luís Vaz Silva 2023-10-01 18:36:42 -03:00 committed by Christoph Oelckers
commit 5e96dbc981
7 changed files with 55 additions and 9 deletions

View file

@ -204,6 +204,7 @@ std2:
'stop' { RET(TK_Stop); }
'null' { RET(TK_Null); }
'nullptr' { RET(ParseVersion >= MakeVersion(4, 9, 0)? TK_Null : TK_Identifier); }
'sealed' { RET(ParseVersion >= MakeVersion(4, 12, 0)? TK_Sealed : TK_Identifier); }
'is' { RET(ParseVersion >= MakeVersion(1, 0, 0)? TK_Is : TK_Identifier); }
'replaces' { RET(ParseVersion >= MakeVersion(1, 0, 0)? TK_Replaces : TK_Identifier); }

View file

@ -122,6 +122,7 @@ xx(TK_Null, "'null'")
xx(TK_Global, "'global'")
xx(TK_Stop, "'stop'")
xx(TK_Include, "'include'")
xx(TK_Sealed, "'sealed'")
xx(TK_Is, "'is'")
xx(TK_Replaces, "'replaces'")