https://issues.dlang.org/show_bug.cgi?id=15721
--- Comment #2 from [email protected] --- I think this is safe to change dispose to: void dispose(A, T)(auto ref A alloc, T p) if (is(T == class) || is(T == interface)) { if (!p) return; auto support = (cast(void*) cast(Object) p)[0 .. typeid(p).init.length]; destroy(p); alloc.deallocate(support); } deallocate doesn't care about the the length of initial static layout of a class. --
