Debian Codegraph @

gcc/testsuite/gdc.test/fail_compilation/test17868.d

raw
1 /*
2 TEST_OUTPUT:
3 ----
4 fail_compilation/test17868.d(10): Error: pragma `crt_constructor` takes no argument
5 fail_compilation/test17868.d(11): Error: pragma `crt_constructor` takes no argument
6 fail_compilation/test17868.d(12): Error: pragma `crt_constructor` takes no argument
7 fail_compilation/test17868.d(13): Error: pragma `crt_constructor` takes no argument
8 ----
9 */
10 pragma(crt_constructor, ctfe())
11 pragma(crt_constructor, 1.5f)
12 pragma(crt_constructor, "foobar")
13 pragma(crt_constructor, S())
14 void foo()
15 {
16 }
17
18 int ctfe()
19 {
20 __gshared int val;
21 return val;
22 }
23
24 struct S {}