On Monday, 19 September 2016 at 11:27:03 UTC, Lodovico Giaretta wrote:
What I'd like to know: is this usage widespread? Should we forbid it for the sake of security?

A big issue I'm finding is that inside most Phobos unittests classes and structs are not marked static even when they could, so putting any restriction on emplace will break most of them.


This of course is not a problem for Phobos (we can easily put static everywhere it's needed), but most DUB packages will probably have the same poor usage of static without the maintainance effort of Phobos (so will remain broken forever).

I already found many (direct or indirect) uses of emplace for non-static nested structs and classes in std.conv, std.typecons and std.experimental.allocator.

Reply via email to