]> gcc.gnu.org Git - gcc.git/blob - gcc/testsuite/g++.dg/cpp0x/constexpr-base6b.C
PR c++/92590 - wrong handling of inherited default ctor.
[gcc.git] / gcc / testsuite / g++.dg / cpp0x / constexpr-base6b.C
1 // CWG issue 2310
2 // { dg-do compile { target c++11 } }
3
4 template<typename A, typename B> struct check_derived_from {
5 static A a;
6 static constexpr B *p = &a; // { dg-error "cannot convert" }
7 int ar[p-p+1]; // { dg-error "13:size of array is not an integral constant-expression" }
8 };
9 struct W { int i; };
10 struct Z : W
11 {
12 check_derived_from<Z, W> cdf;
13 };
This page took 0.039105 seconds and 5 git commands to generate.