1 // PR c++/55879
2 // { dg-do compile { target c++11 } }
3 
4 class CAddress
5 {
6 public:
CAddress(unsigned long begin)7   constexpr CAddress(unsigned long begin) : m_Begin(begin) {}
CAddress(const CAddress & other)8   constexpr CAddress(const CAddress &other) : m_Begin(other.m_Begin) {}
9 
10 private:
11   unsigned long m_Begin;
12 };
13 
14 extern "C" char _lnkDDRRAM;
15 /* internal compiler error on gcc 4.6.3 */
16 const CAddress s_Memmap[2]
17 {
18   {(unsigned long)&_lnkDDRRAM}, /* segmentation fault */
19   {0x40000000},
20 };
21 
22 class CNested {
23 public:
CNested(const CAddress primary)24   constexpr CNested(const CAddress primary)
25     : m_PrimaryBlock(primary) {}
26 
27 private:
28   CAddress m_PrimaryBlock;
29 };
30 
31 /* internal compiler error on gcc 4.7.2 */
32 const CNested s_taskDescriptions[2]
33 {
34   {{0x42000000}},
35   {{0x43000000}},
36 };
37