[llvm-bugs] [Bug 24566] New: Regression for gcc pr43559

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Aug 25 03:21:59 PDT 2015


https://llvm.org/bugs/show_bug.cgi?id=24566

            Bug ID: 24566
           Summary: Regression for gcc pr43559
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: abramo.bagnara at bugseng.com
                CC: dgregor at apple.com, llvm-bugs at lists.llvm.org
    Classification: Unclassified

$ cat partial7.C 
// PR c++/43559

template<typename T, typename U> void f(U&) { }
template<typename T, typename U> void f(T const&) { }

int main()
{
        int a;
        f<int, int const>(a);
}
$ clang++-3.6 -c partial7.C
$ clang++-3.8 -c partial7.C 
partial7.C:9:9: error: call to 'f' is ambiguous
        f<int, int const>(a);
        ^~~~~~~~~~~~~~~~~
partial7.C:3:39: note: candidate function [with T = int, U = const int]
template<typename T, typename U> void f(U&) { }
                                      ^
partial7.C:4:39: note: candidate function [with T = int, U = const int]
template<typename T, typename U> void f(T const&) { }
                                      ^
1 error generated.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150825/605e2c94/attachment.html>


More information about the llvm-bugs mailing list