public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/103105] New: [11 Regression] ICE iterative_hash_template_arg, at cp/pt.c:1790
@ 2021-11-06  1:24 jonathan.poelen at gmail dot com
  2021-11-06  4:49 ` [Bug c++/103105] [11/12 Regression] ICE iterative_hash_template_arg with concepts and varagrs template pinskia at gcc dot gnu.org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: jonathan.poelen at gmail dot com @ 2021-11-06  1:24 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 103105
           Summary: [11 Regression] ICE iterative_hash_template_arg, at
                    cp/pt.c:1790
           Product: gcc
           Version: 11.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: jonathan.poelen at gmail dot com
  Target Milestone: ---

$ cat test.cpp

template<class...>
struct list
{};

template<bool>
struct wrap_in_list_c
{};

template<class x, class... xs>
using wrap_in_list_if_convertible = wrap_in_list_c<
  1 != (... + requires { x() = xs(); })
>;

template<class... xs>
using foo = list<wrap_in_list_if_convertible<xs, xs...>...>;

using L = foo<int,int>;


$ g++ -std=c++20 test.cpp

test.cpp: In substitution of ‘template<class x, class ... xs> using
wrap_in_list_if_convertible = wrap_in_list_c<(1 != (... +requires{x()=
xs();}))> [with x = xs; xs = {xs ...}]’:
test.cpp:15:55:   required from here
test.cpp:10:7: internal compiler error: in iterative_hash_template_arg, at
cp/pt.c:1790
   10 | using wrap_in_list_if_convertible = wrap_in_list_c<
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~
0x1797368 internal_error(char const*, ...)
        ???:0
0x67f8f9 fancy_abort(char const*, int, char const*)
        ???:0
0x7d5ec1 iterative_hash_template_arg(tree_node*, unsigned int)
        ???:0
0x7d5d8f iterative_hash_template_arg(tree_node*, unsigned int)
        ???:0
0x7d5e12 iterative_hash_template_arg(tree_node*, unsigned int)
        ???:0
0x7d5d8f iterative_hash_template_arg(tree_node*, unsigned int)
        ???:0
0x7d5d8f iterative_hash_template_arg(tree_node*, unsigned int)
        ???:0
0x7d5ec1 iterative_hash_template_arg(tree_node*, unsigned int)
        ???:0
0x7e7d16 tsubst(tree_node*, tree_node*, int, tree_node*)
        ???:0
0x7f227c lookup_template_class(tree_node*, tree_node*, tree_node*, tree_node*,
int, int)
        ???:0
0x816d4d finish_template_type(tree_node*, tree_node*, int)
        ???:0
0x7ce2fe c_parse_file()
        ???:0
0x8a252d c_common_parse_file()
        ???:0


Works with g++-10: https://godbolt.org/z/KvM31Yq35

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-04-12 23:49 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-06  1:24 [Bug c++/103105] New: [11 Regression] ICE iterative_hash_template_arg, at cp/pt.c:1790 jonathan.poelen at gmail dot com
2021-11-06  4:49 ` [Bug c++/103105] [11/12 Regression] ICE iterative_hash_template_arg with concepts and varagrs template pinskia at gcc dot gnu.org
2021-11-06  5:00 ` pinskia at gcc dot gnu.org
2021-11-06  8:19 ` [Bug c++/103105] [11/12 Regression] ICE iterative_hash_template_arg with concepts and varagrs template since r11-3261-gb28b621ac67beee8 marxin at gcc dot gnu.org
2021-11-06 14:05 ` ppalka at gcc dot gnu.org
2021-11-08  9:12 ` rguenth at gcc dot gnu.org
2022-04-12 16:59 ` cvs-commit at gcc dot gnu.org
2022-04-12 16:59 ` [Bug c++/103105] [11 " ppalka at gcc dot gnu.org
2022-04-12 20:24 ` jason at gcc dot gnu.org
2022-04-12 23:44 ` cvs-commit at gcc dot gnu.org
2022-04-12 23:46 ` ppalka at gcc dot gnu.org
2022-04-12 23:49 ` ppalka at gcc dot gnu.org

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