Is this intended or is it a bug? void main(string[] args) { Test a; a.foo(5); // Fails to compile } struct Test { mixin testMix; void foo(string y){} } mixin template testMix() { void foo(int x){} }