https://issues.dlang.org/show_bug.cgi?id=24403
Issue ID: 24403 Summary: Nullable doesn't work with non-mutable types with a destructor Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: normal Priority: P1 Component: phobos Assignee: nob...@puremagic.com Reporter: issues.dl...@jmdavisprog.com This code does not compile but should: --- void main() { import std.typecons : Nullable; static struct S { ~this() { } } Nullable!(const S) s; } --- Nullable's destructor is able to handle mutable types but not const or immutable types. --