mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-01-09 17:43:57 +00:00
78704fb6dc
Print the fully qualified names for the overload candidates. This makes it easier to tell what the ambiguity is. Especially if a template is instantiated after a using namespace, it will not inherit the namespace where it was declared. The specialization will give a message about a partial order being ambiguous for the same (unqualified) name, which does not help identify the failure. Addresses PR31450! llvm-svn: 290315
17 lines
470 B
C++
17 lines
470 B
C++
// RUN: %clang_cc1 -fsyntax-only -verify %s
|
|
|
|
namespace n {
|
|
template <int>
|
|
void f(); // expected-note{{explicit instantiation candidate function 'n::f<0>' template here [with $0 = 0]}}
|
|
|
|
extern template void f<0>();
|
|
}
|
|
|
|
using namespace n;
|
|
|
|
template <int>
|
|
void f() {} // expected-note{{explicit instantiation candidate function 'f<0>' template here [with $0 = 0]}}
|
|
|
|
template void f<0>(); // expected-error{{partial ordering for explicit instantiation of 'f' is ambiguous}}
|
|
|