2018-11-07 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / g++.dg / cpp0x / scoped_enum2.C
blob456b0daedd189f57c600c1e875882fd7c6300305
1 // { dg-do compile { target c++11 } }
3 enum class E { e = 10 };
4 enum E2 { e2 = 10 };
6 struct C {
7   int arr[E::e];    // { dg-error "could not convert|non-integral type" }
8   int arr2[E2::e2]; // OK
9   int i: E::e;      // { dg-error "could not convert|non-integral type" }
10   int i2: E2::e2;   // OK