Dynamic Array Question
Steven Schveighoffer
schveiguy at yahoo.com
Thu Sep 22 07:39:14 PDT 2011
On Wed, 21 Sep 2011 00:09:08 -0400, Jesse Phillips
<jessekphillips+d at gmail.com> wrote:
> On Tue, 20 Sep 2011 14:28:54 -0400, Steven Schveighoffer wrote:
>
>> You can deallocate the original array. The soon-to-be-deprecated method
Note: ^^^^^^^^^^^^^^^^^^^^^^^^^
:)
>> (but easiest) is:
>>
>> delete t;
>>
>> To avoid having to change your other code, I'd do this:
>>
>> wchar[] t = ...;
>> scope(exit) delete t; // add this line to the end of the function (after
>> returning)
>
> Unless I missed something, delete is being removed from the language.
-Steve
More information about the Digitalmars-d-learn
mailing list