Re: DIP1000: Should this compile

2019-05-16 Thread Max Haughton via Digitalmars-d-learn
On Thursday, 16 May 2019 at 21:56:52 UTC, Steven Schveighoffer wrote: On 5/16/19 10:21 PM, Max Haughton wrote: https://run.dlang.io/is/cKFsXh Should this compile, or is return scope T* down to the user to not escape (Returning &local directly does not compile) Answer to subject: no. This i

Re: DIP1000: Should this compile

2019-05-16 Thread Simen Kjærås via Digitalmars-d-learn
On Thursday, 16 May 2019 at 21:21:51 UTC, Max Haughton wrote: https://run.dlang.io/is/cKFsXh Should this compile, or is return scope T* down to the user to not escape (Returning &local directly does not compile) This is a bug, as can be showed by repeating the call to (*boi).writeln - sudden

Re: DIP1000: Should this compile

2019-05-16 Thread Steven Schveighoffer via Digitalmars-d-learn
On 5/16/19 10:21 PM, Max Haughton wrote: https://run.dlang.io/is/cKFsXh Should this compile, or is return scope T* down to the user to not escape (Returning &local directly does not compile) Answer to subject: no. This is a bug. Please file. Not sure what the solution is, because dip1000 m