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
Don't warn when alignment of global common data exceeds maximum alignment.
[official-gcc.git]
/
gcc
/
testsuite
/
gdc.dg
/
gdc183.d
blob
aa8a79c53e549461f00b8ca28bb88b9dd9b49028
1
// https://bugzilla.gdcproject.org/show_bug.cgi?id=183
2
// { dg-do compile }
3
4
struct
S183a
5
{
6
union
I183a
7
{
8
struct
9
{
10
double
x
,
y
,
z
;
11
}
12
struct
13
{
14
double
a
,
b
,
c
;
15
}
16
}
17
18
I183a inner
;
19
20
this
(
double
x
,
double
y
,
double
z
)
21
{
22
this
.
inner
.
x
=
x
;
23
this
.
inner
.
y
=
y
;
24
this
.
inner
.
z
=
z
;
25
}
26
}
27
28
struct
S183b
29
{
30
@property
get
()
31
{
32
union
Buf
33
{
34
void
[
0
]
result
;
35
}
36
const
Buf buf
= { };
37
return
buf
.
result
;
38
}
39
}
40
41
struct
S183c
42
{
43
@property
get
()
44
{
45
union
Buf
46
{
47
TypeInfo info
;
48
void
[
0
]
result
;
49
}
50
const
Buf buf
= { };
51
return
buf
.
result
;
52
}
53
}
54
55
void
test183
()
56
{
57
auto
v1
=
S183a
(
0
,
0
,
0
);
58
auto
v2
=
S183b
().
get
;
59
auto
v3
=
S183c
().
get
;
60
}