https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64758
Bug ID: 64758 Summary: [C++11] Give better error message when name of enum's base type cannot be resolved Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: zeratul976 at hotmail dot com For the following invalid code: enum Waldo : uint32_t { // oops, forgot to include <stdint.h> A, B }; GCC's error message is: test.cpp:1:6: error: use of enum ‘Waldo’ without previous declaration enum Waldo : uint32_t { ^ test.cpp:1:12: error: expected unqualified-id before ‘:’ token enum Waldo : uint32_t { ^ This error doesn't really match the problem. A much better error would be: test.cpp:1:6: error: use of ‘uint32_t’ without previous declaration enum Waldo : uint32_t { ^