mirror of
https://github.com/cc65/cc65.git
synced 2025-01-11 11:30:13 +00:00
Warning about forward declaration of enum types in non-cc65 modes.
This commit is contained in:
parent
8cdffc1944
commit
b2d3b8379c
@ -276,6 +276,15 @@ static void Parse (void)
|
|||||||
Entry->Name, Entry->V.BssName);
|
Entry->Name, Entry->V.BssName);
|
||||||
}
|
}
|
||||||
Entry->V.BssName = xstrdup (bssName);
|
Entry->V.BssName = xstrdup (bssName);
|
||||||
|
|
||||||
|
/* Check for enum forward declaration.
|
||||||
|
** Warn about it when extensions are not allowed.
|
||||||
|
*/
|
||||||
|
if (Size == 0 && IsTypeEnum (Decl.Type)) {
|
||||||
|
if (IS_Get (&Standard) != STD_CC65) {
|
||||||
|
Warning ("ISO C forbids forward references to 'enum' types");
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user