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

--- Comment #1 from Kenji Hara <k.hara...@gmail.com> ---
The shown line number is not wrong.

The closure environment that is closing variable foo, is allocated at the start
of function test() == line 1. The delegate literal at line 4 just refers it.

So, the issue would be:
1. the message text that is not enough helpful (diagnostic), or
2. lack of information about the location where the closed variable 'foo' is
used from (enhancement).

--

Reply via email to