This compiles:
int function(int) pure my_func_ptr;
struct WronglyPure {
static opDispatch(string fn, Args...)(Args args) {
return mixin(fn)(args);
}
}
int test() pure {
return WronglyPure.my_func_ptr(1);
}
Evidently, `opDispatch` is deduced as pure, but it shouldn't be, because it access the global variable `my_func_ptr`.