https://issues.dlang.org/show_bug.cgi?id=21868
--- Comment #7 from Walter Bright <bugzi...@digitalmars.com> --- (In reply to Walter Bright from comment #5) > Minimized test case: > > ref int test(ref scope return int* p) > { > return *p; > } This is a separate bug, so moved to: https://issues.dlang.org/show_bug.cgi?id=22108 --