Can not reproduce on current master. I get: bug143.d:3: error: template instance f!(function () { g("f(A)"); } ) does not match template declaration (null)