The code is as follows:
namespace n1
{
template <class T>
void n2();
template <class T>
void n2(T);
}
namespace n2
{
class c {};
}
using namespace n1;
namespace n3
{
void foo(n2::c);
}
void n3::foo(n2::c)
{
}
When I try to compile it using the latest version of Visual C ++, I get the following error:
1>test.cpp(24): error C2872: 'n2': ambiguous symbol
1>test.cpp(12): note: could be 'n2'
1>test.cpp(24): note: or 'n2'
Lines 12 and 24 are marked in the previous code fragment with comments.
? foo n2:: c , , , , , , - , , n2 n1, , : 12 , n2 ( 24). ?