Let's get the semantic around closure fixed.
deadalnix
deadalnix at gmail.com
Tue May 18 19:37:54 UTC 2021
On Tuesday, 18 May 2021 at 17:40:17 UTC, Max Haughton wrote:
> On Tuesday, 18 May 2021 at 16:47:03 UTC, deadalnix wrote:
>> Long story short:
>> https://issues.dlang.org/show_bug.cgi?id=21929
>>
>> Closure do not respect scope the way they should. Let's fix it.
>
> Time to consider by-value captures? Closures (specifically the
> way they interact with the GC) seem problematic in general, not
> just here.
No need, but a new closure is needed for each loop iteration in
which there is a capture.
More information about the Digitalmars-d
mailing list