[Dlang-internal] DIP1000 discussion and testing
Walter Bright via Dlang-internal
dlang-internal at puremagic.com
Wed Oct 26 17:41:35 PDT 2016
On 10/25/2016 5:39 PM, Martin Nowak wrote:
> From my still limited understanding, the lifetime of the return value should be
> bound to the minimum (shortest) lifetime of all arguments that could potentially
> be aliased.
That's right.
> So if the return value is a struct containing an int* and a S*, it might alias
> any argument containing/or being an int or S (and maybe untyped memory).
If that parameter is marked "return scope", then yes.
More information about the Dlang-internal
mailing list