1 // PR c++/47199
2 // { dg-do compile { target c++11 } }
3 // { dg-options "-fno-elide-constructors" }
4 
5 template < int > struct S
6 {
SS7   constexpr S (int r):rr (r)
8   {
9   }
10   S (const S &) = default;
sS11   static constexpr S s ()
12   {
13     return -1;
14   }
15   int rr;
16 };
17 
18 static const int d = S < 0 >::s ().rr;
19