d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.
[official-gcc.git] / gcc / testsuite / gdc.test / fail_compilation / bug15613.d
blob5b16f72ca232ebf11ced105efad69c4e728a32c4
1 /*
2 TEST_OUTPUT:
3 ---
4 fail_compilation/bug15613.d(16): Error: function `bug15613.f(int...)` is not callable using argument types `(typeof(null))`
5 fail_compilation/bug15613.d(16): cannot pass argument `null` of type `typeof(null)` to parameter `int...`
6 fail_compilation/bug15613.d(17): Error: function `bug15613.g(Object, ...)` is not callable using argument types `(int)`
7 fail_compilation/bug15613.d(17): cannot pass argument `8` of type `int` to parameter `Object`
8 ---
9 */
11 void f(int...);
12 void g(Object, ...);
14 void main()
16 f(null);
17 g(8);
21 TEST_OUTPUT:
22 ---
23 fail_compilation/bug15613.d(32): Error: function `bug15613.h(int[]...)` is not callable using argument types `(int, void function(int[]...))`
24 fail_compilation/bug15613.d(32): cannot pass argument `& h` of type `void function(int[]...)` to parameter `int[]...`
25 ---
28 void h(int[]...);
30 void test()
32 h(7, &h);