http://llvm.org/bugs/show_bug.cgi?id=9440
Summary: Clang doesn't trigger template instantiation to find
friend function definitions (ADL)
Product: clang
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected], [email protected]
Clang currently rejects this:
template<typename T>
struct A {
friend void f(A *) { }
};
int main() {
f((A<int>*)0);
}
main1.cpp:7:5: error: use of undeclared identifier 'f'
f((A<int>*)0);
^
Closed issue report 34 reassured that this code is valid.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs