public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "anbu1024.me at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c/109618] New: ICE: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in generic_simplify_CONVERT_EXPR, at generic-match.cc Date: Tue, 25 Apr 2023 05:53:14 +0000 [thread overview] Message-ID: <bug-109618-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109618 Bug ID: 109618 Summary: ICE: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in generic_simplify_CONVERT_EXPR, at generic-match.cc Product: gcc Version: 13.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: anbu1024.me at gmail dot com Target Milestone: --- $ cat test.c int foo() { const unsigned int var_1 = 2; char var_5[var_1]; int var_1[10]; return sizeof(var_5); } -------------------------------- $ gcc --version gcc (GCC) 13.0.1 20230219 (experimental) Copyright (C) 2023 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -------------------------------- $ gcc test.c test.c: In function ‘foo’: test.c:8:7: error: conflicting type qualifiers for ‘var_1’ 8 | int var_1[10]; | ^~~~~ test.c:4:22: note: previous definition of ‘var_1’ with type ‘unsigned int’ 4 | const unsigned int var_1 = 2; | ^~~~~ test.c :10:3: internal compiler error: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in generic_simplify_CONVERT_EXPR, at generic-match.cc:28499 10 | return sizeof(var_5); | ^~~~~~ 0x840637 tree_class_check_failed(tree_node const*, tree_code_class, char const*, int, char const*) ../../gcc-13-20230219/gcc/tree.cc:8959 0x8abac0 tree_class_check(tree_node*, tree_code_class, char const*, int, char const*) ../../gcc-13-20230219/gcc/tree.h:3653 0x8abac0 generic_simplify_CONVERT_EXPR gcc-13-20230219-build/gcc/generic-match.cc:28499 0xbf6848 fold_unary_loc(unsigned int, tree_code, tree_node*, tree_node*) ../../gcc-13-20230219/gcc/fold-const.cc:9341 0xbf8079 fold_build1_loc(unsigned int, tree_code, tree_node*, tree_node*) ../../gcc-13-20230219/gcc/fold-const.cc:13778 0x9429bb c_expr_sizeof_expr(unsigned int, c_expr) ../../gcc-13-20230219/gcc/c/c-typeck.cc:3096 0x97ef46 c_parser_sizeof_expression ../../gcc-13-20230219/gcc/c/c-parser.cc:8910 0x97ef46 c_parser_unary_expression ../../gcc-13-20230219/gcc/c/c-parser.cc:8803 0x97fdef c_parser_cast_expression ../../gcc-13-20230219/gcc/c/c-parser.cc:8672 0x9800df c_parser_binary_expression ../../gcc-13-20230219/gcc/c/c-parser.cc:8440 0x98154b c_parser_conditional_expression ../../gcc-13-20230219/gcc/c/c-parser.cc:8138 0x981d24 c_parser_expr_no_commas ../../gcc-13-20230219/gcc/c/c-parser.cc:8052 0x981fd1 c_parser_expression ../../gcc-13-20230219/gcc/c/c-parser.cc:11379 0x982717 c_parser_expression_conv ../../gcc-13-20230219/gcc/c/c-parser.cc:11419 0x97858b c_parser_statement_after_labels ../../gcc-13-20230219/gcc/c/c-parser.cc:6674 0x9798e4 c_parser_compound_statement_nostart ../../gcc-13-20230219/gcc/c/c-parser.cc:6296 0x99f164 c_parser_compound_statement ../../gcc-13-20230219/gcc/c/c-parser.cc:6105 0x9a10cb c_parser_declaration_or_fndef ../../gcc-13-20230219/gcc/c/c-parser.cc:2841 0x9a8a1b c_parser_external_declaration ../../gcc-13-20230219/gcc/c/c-parser.cc:1925 0x9a93f3 c_parser_translation_unit ../../gcc-13-20230219/gcc/c/c-parser.cc:1779 Please submit a full bug report, with preprocessed source (by using -freport-bug). Please include the complete backtrace with any bug report. See <https://gcc.gnu.org/bugs/> for instructions.
next reply other threads:[~2023-04-25 5:53 UTC|newest] Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top 2023-04-25 5:53 anbu1024.me at gmail dot com [this message] 2023-04-25 6:37 ` [Bug c/109618] " rguenth at gcc dot gnu.org 2023-04-27 6:59 ` [Bug c/109618] ICE: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in generic_simplify_CONVERT_EXPR, at generic-match.cc since r12-3278-g823685221de986 marxin at gcc dot gnu.org 2024-03-23 20:27 ` [Bug c/109618] [12/13/14 Regression] " pinskia at gcc dot gnu.org 2024-03-23 20:38 ` pinskia 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-109618-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: 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).