Issue 9148 - 'pure' is broken

https://issues.dlang.org/show_bug.cgi?id=9148

A nested function inside `pure` function should also be typed as `pure`, and considered as weak purity function.
> The return type of test() would be int delegate()[]. Then the calls f[0]() and f[1]() in main are impure and the behaviour is not at all surprising.

By returning a tuple instead of an array, you can see the behavior that pure delegate call `f[0]()` will be violated by the impure `f[1]()` call.

Ok @tghr, now I'm probably understanding what you saying. With simple case, declaring impure nested function inside pure function would be possible.
But I'm really not sure that is possible with complex cases (and useful or not). So today, I cannot say anything more than that.