https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88086
Gábor Buella <gbuella at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gbuella at gmail dot com --- Comment #1 from Gábor Buella <gbuella at gmail dot com> --- This did come up for me as well, when trying to compile: enum [[clang::enum_extensibility(closed)]] dummy { a, b }; $ g++-8 dummy.cc y.cc:2:34: error: ‘closed’ was not declared in this scope enum [[clang::enum_extensibility(closed)]] dummy { a, b }; ^~~~~~ y.cc:2:34: note: suggested alternative: ‘class’ enum [[clang::enum_extensibility(closed)]] dummy { a, b }; ^~~~~~ class y.cc:2:44: warning: ‘clang::enum_extensibility’ scoped attribute directive ignored [-Wattributes] enum [[clang::enum_extensibility(closed)]] dummy { a, b }; ^~~~~ It is rather annoying, the attribute is ignored, but there is a compile error.