Value closures (no GC allocation)

Adam D. Ruppe via Digitalmars-d digitalmars-d at puremagic.com
Wed May 24 20:42:11 PDT 2017


On Thursday, 25 May 2017 at 03:30:38 UTC, Stanislav Blinov wrote:
> Captures, if any, should be explicit. That is all :)

The current behavior is fine in most cases. The explicit by-value 
capture handles the remaining cases.

> By inference, adding capture syntax at all will also complicate 
> the whole thing.

Yeah, there's some complication in adding it but it is worth it 
because it gives something new without breaking anything old.

> P.S. have you seen the TODO at the bottom of that section?

Yeah, I'm EXTREMELY against removing the current behavior. I'd 
kill the whole thing just to avoid that.


More information about the Digitalmars-d mailing list