Michel Fortin wrote: > This compiles, but should it? > > @safe > ref int foo(ref int a) { > return a; > } > > @safe > ref int bar() { > int a; > return foo(a); // leaking reference to a beyond bar's scope > } No.