Andrei Alexandrescu napisał: > On 1/27/11 4:48 PM, Tomek Sowiński wrote: > > Andrei Alexandrescu napisał: > > > >> ref returns should be guaranteed to never escape. > > > > Should meaning they're not guaranteed now? I'm curious in what scenarios > > they escape. > > Any function can take the address of a reference (either a ref parameter > or the result of another function) and squirrel it away.
Jeez.. I must've had some brain-warp that I didn't think of &r.front :-) But is just banning taking addresses of ref parameters and return values going to solve the problem? Sounds delusively simple... -- Tomek