d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.
[official-gcc.git] / gcc / testsuite / gdc.test / fail_compilation / diaginref.d
blob2e83d76b5623f198f6d9332c86179def00f133a4
1 /*
2 REQUIRED_ARGS: -preview=in
3 TEST_OUTPUT:
4 ---
5 fail_compilation/diaginref.d(11): Error: attribute `ref` is redundant with previously-applied `in`
6 fail_compilation/diaginref.d(13): Error: attribute `in` cannot be added after `ref`: remove `ref`
7 ---
8 */
10 void foo(in string) {}
11 void foo1(in ref string) {}
12 void foo2(T)(in T v, string) {}
13 void foo3(T)(ref in T v, string) {}