public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "pinskia at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/103684] Ambiguous template template overload resolution Date: Mon, 13 Dec 2021 13:22:27 +0000 [thread overview] Message-ID: <bug-103684-4-4TAjB8st4q@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-103684-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=103684 --- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Reduced testcase: template <class T, class T1 = int, class T2 = int> struct f{}; template <class T, class T1 = int> struct g{}; template<template<typename, typename> class T> constexpr int hello() { return 2; } template<template<typename, typename, typename> class T> constexpr int hello() { return 3; } void foo() { auto i = hello<g>(); auto j = hello<f>(); } ----- CUT ----- I think clang here is wrong, MSVC and ICC both reject it for the same reason as GCC. Basically it looks like clang is not taking into account the default template arugments.
next prev parent reply other threads:[~2021-12-13 13:22 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-12-13 13:14 [Bug c++/103684] New: " weidmann at acm dot org 2021-12-13 13:22 ` pinskia at gcc dot gnu.org [this message] 2021-12-13 13:31 ` [Bug c++/103684] " pinskia at gcc dot gnu.org 2021-12-13 13:41 ` weidmann at acm dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-103684-4-4TAjB8st4q@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).