std.allocator ready for some abuse

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Thu Nov 7 09:12:41 PST 2013


On 11/7/13 9:02 AM, Namespace wrote:
> On Thursday, 7 November 2013 at 16:28:42 UTC, Andrei Alexandrescu wrote:
>> On 11/7/13 5:30 AM, Namespace wrote:
>>> Nice! But I suggest two things:
>>>  1. Add a reset function for reusing the same storage
>>
>> freeAll().
>
> There is no freeAll. Did you mean deallocateAll?
> ----
> void deallocateAll()
> {
>     _crt = null;
> }
> ----
> _crt is null and the same storage can't be used again.

Sorry that's indeed the name and there's a bug in it!

Andrei



More information about the Digitalmars-d mailing list