repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
libstdc++: [_Hashtable] Fix some implementation inconsistencies
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
cpp0x
/
union2.C
blob
514409414dc8aca5f24e2828bfec7d4deda1b750
1
// Positive test for C++11 unrestricted unions
2
// { dg-do compile { target c++11 } }
3
4
struct A
5
{
6
A();
7
A(const A&);
8
~A();
9
};
10
11
union B
12
{
13
A a;
14
B();
15
B(const B&);
16
~B();
17
};
18
19
B b;
20
B b2(b);
21
22
struct C
23
{
24
union
25
{
26
A a;
27
};
28
C();
29
C(const C&);
30
~C();
31
};
32
33
C c;
34
C c2(c);