c++: Add test [PR95288]
Somewhat improved by r11-2064, though we still generate junk that seems redundant. But at least it says error: expected ‘}’ before ‘.’ token PR c++/95288 * g++.dg/diagnostic/enum2.C: New test.
This commit is contained in:
parent
776e48e093
commit
6a9a3434c7
10
gcc/testsuite/g++.dg/diagnostic/enum2.C
Normal file
10
gcc/testsuite/g++.dg/diagnostic/enum2.C
Normal file
@ -0,0 +1,10 @@
|
||||
// PR c++/95288
|
||||
|
||||
void f()
|
||||
{
|
||||
enum X
|
||||
{ // { dg-message "to match this" }
|
||||
a. // { dg-error "expected" }
|
||||
b
|
||||
}; // { dg-error "extra" "" { target c++98_only } }
|
||||
} // { dg-error "expected" }
|
Loading…
x
Reference in New Issue
Block a user