On 2/7/15 8:00 PM, H. S. Teoh via Digitalmars-d wrote:
On Sat, Feb 07, 2015 at 06:19:19PM -0800, Andrei Alexandrescu via Digitalmars-d 
wrote:
[...]
private @system T[] mallocUninitializedArrayImpl(T)(size_t n)
{
     auto p = malloc(n * T.sizeof);
     p || assert(0, "Not enough memory");

This is a truly strange way of writing it... why not:

        assert(p !is null, "Not enough memory");

?

assert(0) is not removed in release mode. -- Andrei

Reply via email to