On 30.04.2012 23:14, H. S. Teoh wrote:
On Mon, Apr 30, 2012 at 09:06:06PM +0200, Andrej Mitrovic wrote:
On 4/30/12, H. S. Teoh<hst...@quickfur.ath.cx>  wrote:
Then
you can write:

        uint[] a = [
                2: 100,
                10: 200
        ]

and it will be equivalent to:

        uint[] a = [0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 200];

But you can already use this syntax right now?

Yes I know you can, it was more of using this syntax for user-defined
types without allocating a temporary array.


Yes I tried to point out that this also makes this code straight forward. AND allows other AA-like enitites to benefit from it.

Most importantly it doesn't break a thing. Just generalizes.
--
Dmitry Olshansky

Reply via email to