In the meanwhile I found that this ICE has nothing to do with templates and namespaces, but is a problem of typeof(X) when the type of X cannot be uniquely derived. The same ICE occurs in the following code: double f(double); float f(float); void h(typeof(f) g) {} Helmut