https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64758
--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- It got worse (maybe better) in GCC 9.4.0 and 10+: <source>:3:14: error: found ':' in nested-name-specifier, expected '::' 3 | enum Waldo : uint32_t { // oops, forgot to include <stdint.h> | ^ | :: <source>:3:8: error: 'Waldo' has not been declared 3 | enum Waldo : uint32_t { // oops, forgot to include <stdint.h> | ^~~~~ <source>:3:25: error: expected unqualified-id before '{' token 3 | enum Waldo : uint32_t { // oops, forgot to include <stdint.h> | ^