https://issues.dlang.org/show_bug.cgi?id=22284

Dennis <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]
           Hardware|x86_64                      |All
                 OS|Linux                       |All

--- Comment #1 from Dennis <[email protected]> ---
I'm not sure why your cannotInfer examples fail, but canInfer3 and canInfer4
succeed because the parameter (This bar) in the lambda is inferred scope since
it's passed by value and the lambda is `pure` and returns `void`, so it can't
escape `arr`. The `scope` annotation of canInfer3 doesn't do anything since
it's not a `delegate` but a `function` since you pass `this` explicitly through
parameter `bar`.

--

Reply via email to