public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "gscfq@t-online.de" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/107422] New: [12/13 Regression] ICE in lvalue_kind, at cp/tree.cc:293
Date: Wed, 26 Oct 2022 18:34:22 +0000	[thread overview]
Message-ID: <bug-107422-4@http.gcc.gnu.org/bugzilla/> (raw)

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

            Bug ID: 107422
           Summary: [12/13 Regression] ICE in lvalue_kind, at
                    cp/tree.cc:293
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: gscfq@t-online.de
  Target Milestone: ---

Started with r12 before 20210502 :
(gcc configured with --enable-checking=yes)


$ cat z1.cc
typedef decltype (__builtin_trap) t;
template <int> struct s;
union
{
  template <int a> using b = decltype (t () (s <a> {}));
  template <int a> b <a> get ();
};  // } u;


$ g++-13-20221023 -c z1.cc -fno-pretty-templates
z1.cc:5:26: error: 'template<int a> using<unnamed union>::b = decltype
(t()(s<a>{}))' invalid; an anonymous union may only have public non-static data
members [-fpermissive]
    5 |   template <int a> using b = decltype (t () (s <a> {}));
      |                          ^
'
Segmentation fault
    7 | };  // } u;
      | ^
0x11d0e4f crash_signal
        ../../gcc/toplev.cc:314
0xb15510 lvalue_kind(tree_node const*)
        ../../gcc/cp/tree.cc:293
0xae9fa7 finish_decltype_type(tree_node*, bool, int)
        ../../gcc/cp/semantics.cc:11488
0xb271af strip_typedefs(tree_node*, bool*, unsigned int)
        ../../gcc/cp/tree.cc:1788
0x91ae45 dump_type
        ../../gcc/cp/error.cc:538
0x91a6fc dump_type_prefix
        ../../gcc/cp/error.cc:981
0x92578d dump_function_decl
        ../../gcc/cp/error.cc:1804
0x9287f6 decl_to_string
        ../../gcc/cp/error.cc:3297
0x9287f6 cp_printer
        ../../gcc/cp/error.cc:4471
0x2202490 pp_format(pretty_printer*, text_info*)
        ../../gcc/pretty-print.cc:1475
0x21e13c0 diagnostic_report_diagnostic(diagnostic_context*, diagnostic_info*)
        ../../gcc/diagnostic.cc:1548
0x21e1b0a diagnostic_impl
        ../../gcc/diagnostic.cc:1712
0x21e224a permerror(unsigned int, char const*, ...)
        ../../gcc/diagnostic.cc:1979
0x8c30e7 fixup_anonymous_aggr(tree_node*)
        ../../gcc/cp/decl.cc:5194
0x8ea67c shadow_tag(cp_decl_specifier_seq*)
        ../../gcc/cp/decl.cc:5498
0xa011c9 cp_parser_simple_declaration
        ../../gcc/cp/parser.cc:15422
0xa35d9b cp_parser_declaration
        ../../gcc/cp/parser.cc:14970
0xa368b8 cp_parser_translation_unit
        ../../gcc/cp/parser.cc:5076
0xa368b8 c_parse_file()
        ../../gcc/cp/parser.cc:48860
0xbcef21 c_common_parse_file()
        ../../gcc/c-family/c-opts.cc:1247

             reply	other threads:[~2022-10-26 18:34 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-26 18:34 gscfq@t-online.de [this message]
2022-10-26 19:17 ` [Bug c++/107422] " mpolacek at gcc dot gnu.org
2022-10-27  8:53 ` [Bug c++/107422] [12/13 Regression] ICE in lvalue_kind, at cp/tree.cc:293 since r12-298-g58a92b789a77cdad marxin at gcc dot gnu.org
2022-10-28 11:35 ` rguenth at gcc dot gnu.org
2023-05-08 12:25 ` [Bug c++/107422] [12/13/14 " rguenth at gcc dot gnu.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-107422-4@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: link
Be 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).