DIP 1021--Argument Ownership and Function Calls--Community Review Round 1
Nick Treleaven
nick at geany.org
Sat Jul 20 07:14:33 UTC 2019
On Friday, 19 July 2019 at 20:03:22 UTC, Walter Bright wrote:
> However, if that container exposes its internals by ref, then
> it is safe with this DIP, because ref does not span statements.
Timon has disproved this:
https://forum.dlang.org/post/qgsroo$1l8n$1@digitalmars.com
With that struct container as a member of a class, you can have
multiple class references to the same class instance and pass one
of those to a function with a ref argument of the struct-owned
heap memory.
More information about the Digitalmars-d
mailing list