https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64758
--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> --- (In reply to Jonathan Wakely from comment #4) > I suggest that we should notice that ": bar" is bad, give an error about > "bar" being undeclared, and then act as though no enum-base was present for > the rest of the compilation. All the other diagnostics should vanish at that > point. That seems to be what Clang does: e.C:1:18: error: unknown type name 'bar' enum class foo : bar { baz }; ^ 1 error generated. There's no error about foo::baz, presumably because after realising the enum-base was bad, they just skipped it and still compiled the enumerator-list successfully. EDG gives pretty much the same errors as GCC though.