Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/g++.dg/cpp0x/scoped_enum2.C @ 111:04ced10e8804
gcc 7
author | kono |
---|---|
date | Fri, 27 Oct 2017 22:46:09 +0900 |
parents | |
children | 84e7813d76e9 |
comparison
equal
deleted
inserted
replaced
68:561a7518be6b | 111:04ced10e8804 |
---|---|
1 // { dg-do compile { target c++11 } } | |
2 | |
3 enum class E { e = 10 }; | |
4 enum E2 { e2 = 10 }; | |
5 | |
6 struct C { | |
7 int arr[E::e]; // { dg-error "non-integral type" } | |
8 int arr2[E2::e2]; // OK | |
9 int i: E::e; // { dg-error "non-integral type" } | |
10 int i2: E2::e2; // OK | |
11 }; |