https://issues.dlang.org/show_bug.cgi?id=19916
Nick Treleaven <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #24 from Nick Treleaven <[email protected]> --- (In reply to Simen Kjaeraas from comment #5) > struct NotAPointer { > private size_t n; > @disable this(); > @trusted this(int* p) { > assert(p.isValid); > n = cast(size_t)p; > } > @trusted void callMethod() { > *cast(int*)n = 3; > } > } The answer to this is to mark `n` as `@system`. --
