Found the right answer after 3 months of searching :) It's in 14.6.1/4
of the Standard:
A template-parameter shall not be redeclared within its scope (including nested scopes). A template-parameter shall not have the same name as the template name.
Example:
template<class T, int i> class Y {
int T;
// error: template-parameter redeclared
void f() {
char T;
// error: template-parameter redeclared
}
};
template<class X> class X; // error: template-parameter redeclared
If the Microsoft compiler let it compile without errors or even warnings, it is not conforming. I don't know what could drive it to allow it without moaning. You could try to high warning levels.