(root)/
gcc-13.2.0/
gcc/
testsuite/
gdc.test/
fail_compilation/
pull12941.d
/* TEST_OUTPUT:
---
fail_compilation/pull12941.d(110): Error: `pull12941.foo` called with argument types `(int*)` matches both:
fail_compilation/pull12941.d(101):     `pull12941.foo(return ref scope int* p)`
and:
fail_compilation/pull12941.d(102):     `pull12941.foo(return out scope int* p)`
fail_compilation/pull12941.d(111): Error: function `pull12941.bar(return scope int* p)` is not callable using argument types `(int)`
fail_compilation/pull12941.d(111):        cannot pass argument `1` of type `int` to parameter `return scope int* p`
fail_compilation/pull12941.d(112): Error: function `pull12941.abc(return ref int* p)` is not callable using argument types `(int)`
fail_compilation/pull12941.d(112):        cannot pass rvalue argument `1` of type `int` to parameter `return ref int* p`
---
 */

/*********************************/
// Tests for https://github.com/dlang/dmd/pull/12941

#line 100

int* foo(ref scope return int* p);
int* foo(out scope return int* p);

int* bar(scope return int* p);
int* abc(ref return int* p);

void test()
{
    int* p;
    foo(p);
    bar(1);
    abc(1);
}