https://issues.dlang.org/show_bug.cgi?id=13859
Issue ID: 13859
Summary: Phobos uninitializedAlloc
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Severity: enhancement
Priority: P1
Component: Phobos
Assignee: [email protected]
Reporter: [email protected]
I suggest to add to Phobos a simple function like this one:
T* uninitializedAlloc(T)() pure nothrow @trusted {
return cast(T*)GC.malloc(T.sizeof);
}
Such function can also take a little care for the presence of internal pointers
to better tell the GC about their absence or presence.
--