sumtype 0.5.0
vit
vit at vit.vit
Thu Aug 9 08:06:15 UTC 2018
On Thursday, 9 August 2018 at 01:04:43 UTC, Paul Backus wrote:
> ...
@safe opAssign can call @system postblit:
bool moved = false;
struct S{
this(this)@system{
moved = true;
}
}
void main()@safe{
auto st = SumType!(S).init;
st = S.init;
assert(moved == true);
}
change:
() @trusted { moveEmplace(rhs, storage.values[i]); }();
to:
moveEmplace(rhs, *(() @trusted => &storage.values[i])());
More information about the Digitalmars-d-announce
mailing list