c++: Fix tentative parsing of enum-specifier [PR96077]