Avoid GC with closures

Dicebot via Digitalmars-d digitalmars-d at puremagic.com
Sun May 29 04:16:57 PDT 2016


On 05/28/2016 09:58 PM, Iakh wrote:
> Yeah. It doesn't capture any context. But once it does it
> would be an error.

Custom allocators are not very suitable for things like closures because
of undefined lifetime. Even if it was allowed to replace allocator, you
would be limited to either GC or RC based one anyway to keep things @safe.


More information about the Digitalmars-d mailing list