[Issue 20149] [DIP1000] Local data escapes `opSlice` if not annotated with `return`

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Aug 22 05:48:34 UTC 2019


https://issues.dlang.org/show_bug.cgi?id=20149

--- Comment #2 from Mike Franklin <slavo5150 at yahoo.com> ---
Interestingly removing the `inout` attribution on `opSlice` causes the compiler
to emit an error at the return statement in `fun`.  I think the error should
instead be emitted at the return statement of `opSlice`, but at least it
doesn't compile.

--


More information about the Digitalmars-d-bugs mailing list