On Friday, 8 April 2022 at 04:31:45 UTC, Elvis Zhou wrote: > B b; > init(\&b); > structs ~= cast(A*)\&b; > //Error: copying `cast(A*)\& b` into allocated memory escapes a > reference to local variable `b` Maybe it should be `cast(A*) \&b.a`?