aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/cpp0x/nsdmi10.C
blob: 56f9ff08bdf4b361b58d7d5a9a7c96430bdd8107 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// PR c++/58328
// { dg-do compile { target c++11 } }

struct A1 {
  struct B1 {
    int y1 = 1;
  };

  A1(const B1& opts = B1()) {}  // { dg-error "constructor" }
};

struct A2 {
  struct B2 {
    int x2, y2 = 1;
  };

  A2(const B2& opts = B2()) {}  // { dg-error "constructor" }
};