MATCH: Improve `A CMP 0 ? A : -A` set of patterns to use bitwise_equal_p.
[official-gcc.git] / gcc / testsuite / gdc.test / fail_compilation / test14496.d
blob94d5d0ffc5ffb585637a142fac057219384fad86
1 /*
2 TEST_OUTPUT:
3 ---
4 fail_compilation/test14496.d(21): Error: `void` initializers for pointers not allowed in safe functions
5 fail_compilation/test14496.d(24): Error: `void` initializers for pointers not allowed in safe functions
6 fail_compilation/test14496.d(28): Error: `void` initializers for pointers not allowed in safe functions
7 fail_compilation/test14496.d(48): Error: `void` initializers for pointers not allowed in safe functions
8 fail_compilation/test14496.d(49): Error: `void` initializers for pointers not allowed in safe functions
9 fail_compilation/test14496.d(50): Error: `void` initializers for pointers not allowed in safe functions
10 ---
12 // https://issues.dlang.org/show_bug.cgi?id=14496
13 @safe void foo()
15 struct Foo {
16 int* indirection1;
17 Object indirection2;
18 string[] indirection3;
21 Foo f = void;
23 struct Bar {
24 Foo foo = void;
27 struct Baz {
28 int* x = void;
33 struct Foo {
34 int* indirection1;
35 Object indirection2;
36 string[] indirection3;
39 struct Bar {
40 Foo foo = void;
43 struct Baz {
44 int* x = void;
47 @safe void sinister() {
48 Bar bar;
49 Baz baz;
50 Bar[2] bars; // https://issues.dlang.org/show_bug.cgi?id=23412