TempAlloc review starts now

bearophile bearophileHUGS at lycos.com
Sun Jun 5 18:29:21 PDT 2011


Andrei:

> new T[size](void) and new T[size](initializer) have been discussed,

Isn't this syntax:
new int[](15)
already equivalent to this?
new int[15]


The mix of square and round parentheses D uses to define and allocate dynamic is confusing for me and I don't like it, especially when you want to allocate a multi-dimensional array where some dimensions are fixed-sized arrays and others are dynamic. I have never written a bug report on this because I don't think this syntax will change and because after hundreds of usages I think it's coherent, despite looking somewhat messy.

Bye,
bearophile


More information about the Digitalmars-d mailing list