mirror of
https://github.com/byteworksinc/ORCA-C.git
synced 2024-12-30 14:31:04 +00:00
Ignore storage class when creating enum tag symbols.
This avoids strangeness where an enum tag declared within a typedef declaration would act like a typedef. For example, the following would compile without error: typedef enum E {a,b,c} T; E e;
This commit is contained in:
parent
2cbcdc736c
commit
c36bf9bf0a
@ -3194,7 +3194,7 @@ while token.kind in allowedTokens do begin
|
||||
tPtr^.qualifiers := [];
|
||||
tPtr^.kind := enumType;
|
||||
variable :=
|
||||
NewSymbol(ttoken.name, tPtr, storageClass, tagSpace, defined);
|
||||
NewSymbol(ttoken.name, tPtr, ident, tagSpace, defined);
|
||||
end {if}
|
||||
else if token.kind <> lbracech then
|
||||
Error(9);
|
||||
|
Loading…
Reference in New Issue
Block a user