The demise of T[new]

Bill Baxter wbaxter at gmail.com
Mon Oct 19 04:35:57 PDT 2009


On Mon, Oct 19, 2009 at 2:48 AM, Walter Bright
<newshound1 at digitalmars.com> wrote:
> Ary Borenszweig wrote:
>>
>> I remember seeing a lot of CTFE code that created a dynamic array and then
>> appended stuff to it, like for example to build a list of prime numbers.
>> Would that still work with ArrayBuilder?
>
> Probably not. But you can rewrite:
>
>  a ~= stuff;
>
> as:
>
>  a = a ~ stuff;
>
> to make it work.

Ouch.  Gives me Matlab nightmares.

--bb



More information about the Digitalmars-d mailing list