https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120382
Bug ID: 120382
Summary: internal compiler error: tree check: expected class
'type', have 'exceptional' (error_mark) in
extended_tree, at tree.h:6562
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: xieym3 at zohomail dot com
Target Milestone: ---
$ cat file.c
typedef int __attribute__((hardbool(0, a))) B;
$ gcc -v
Using built-in specs.
COLLECT_GCC=/data/xieym/work-rgf/misc_tools/install/gcc-trunk/bin/gcc
COLLECT_LTO_WRAPPER=/data/xieym/work-rgf/misc_tools/install/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/16.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /data/xieym/work-rgf/misc_tools/src/gcc-trunk/configure
--enable-coverage --enable-checking --disable-multilib --disable-shared
--disable-bootstrap --enable-language=c,c++
--prefix=/data/xieym/work-rgf/misc_tools/install/gcc-trunk
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 16.0.0 20250519 (experimental) (GCC)
$ gcc -c file.c -o /dev/null
<source>:1:1: internal compiler error: tree check: expected class 'type', have
'exceptional' (error_mark) in extended_tree, at tree.h:6562
1 | typedef int __attribute__((hardbool(0, a))) B;
| ^~~~~~~
0x260c7a5 diagnostic_context::diagnostic_impl(rich_location*,
diagnostic_metadata const*, diagnostic_option_id, char const*, __va_list_tag
(*) [1], diagnostic_t)
???:0
0x262a516 internal_error(char const*, ...)
???:0
0x8fab53 tree_class_check_failed(tree_node const*, tree_code_class, char
const*, int, char const*)
???:0
0xa0ea76 decl_attributes(tree_node**, tree_node*, int, tree_node*)
???:0
0xa307b9 start_decl(c_declarator*, c_declspecs*, bool, tree_node*, bool,
unsigned long*)
???:0
0xabbbee c_parse_file()
???:0
0xb3c959 c_common_parse_file()
???:0
Godbolt url: https://godbolt.org/z/5bnnPThWE