cannot use delegates as parameters to non-global template

This pretty severely impacts the usability of template alias parameters for lambda functions. class Foo { uint doStuff(alias fun)(uint a, uint b) { return fun(a, b); } } void main() { auto foo = new Foo; uint add(uint a, uint b) { return a + b; } foo.doStuff!add(1, 2); } test9.d(10): Error: template instance cannot use local 'add' as parameter to non-global template doStuff(alias fun)