This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/80679] New: call of overloaded is ambiguous


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80679

            Bug ID: 80679
           Summary: call of overloaded is ambiguous
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: thomas.sanchz at gmail dot com
  Target Milestone: ---

Hi,
First reported there https://github.com/mapbox/jni.hpp/pull/17
The following code is compiling fine on clang but fails on g++

////
template <class T>
class Method {};

template <class R, class... Args>
void Call(const Method<R (Args...)>&, const Args&... args) {}

template <class... Args>
void Call(const Method<void (Args...)>&, const Args&... args) {}

int main() {
    Call(Method<void (int)>(), int());
}
////

Cheers,

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]