DMD 0.167 release

Jarrett Billingsley kb3ctd2 at yahoo.com
Mon Sep 18 13:13:36 PDT 2006


"Jarrett Billingsley" <kb3ctd2 at yahoo.com> wrote in message 
news:eemsjf$1l1a$1 at digitaldaemon.com...
> "Walter Bright" <newshound at digitalmars.com> wrote in message 
> news:eemqtr$1iaj$1 at digitaldaemon.com...
>> Array literals, by popular demand.
>>
>> http://www.digitalmars.com/d/changelog.html
>
> o Added support for multidimensional array allocation with NewExpression.
> o Added array literals.
> o std.format will now work with struct arguments as long as they define a 
> char[] toString() member function.
>
> Three very, very tasty new features.  Thank you so much :)
>
> And I guess you're still updating the docs.

Don't know if this is a bug..

void fork(int[] x)
{
    foreach(i; x)
        writefln(i);
}

..
fork([1, 2, 3]);

That works fine.  But:

int[] x = [1, 2, 3];

Fails, since "x is not a static and cannot have static initializer."

Maybe that detection has to be removed? 





More information about the Digitalmars-d-announce mailing list