[LLVMbugs] [Bug 8598] New: Failed template argument deduction involving member function pointers

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Sat Nov 13 07:50:01 PST 2010


http://llvm.org/bugs/show_bug.cgi?id=8598

           Summary: Failed template argument deduction involving member
                    function pointers
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: dgregor at apple.com
                CC: llvmbugs at cs.uiuc.edu, dgregor at apple.com


jhelom:clang dgregor$ cat t.cpp 
    template<class T> struct identity { typedef T type; };

    template<class T, class C>
    void f(T C::*, typename identity<T>::type*){}

    struct X { void f() {}; };

    int main() { f(&X::f, 0); }


jhelom:clang dgregor$ clang++ t.cpp 
t.cpp:8:18: error: no matching function for call to 'f'
    int main() { f(&X::f, 0); }
                 ^
t.cpp:4:10: note: candidate template ignored: failed template argument
deduction
    void f(T C::*, typename identity<T>::type*){}
         ^


(This is from core issue 1184)

-- 
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.



More information about the llvm-bugs mailing list