https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126127
Bug ID: 126127
Summary: ICE: imported user-defined operator with
iso_fortran_env type rename
Product: gcc
Version: 16.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: simon at whiteowl dot co.uk
Target Milestone: ---
Created attachment 64948
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=64948&action=edit
Reproducer for ICE
Tested with 12.3.0, 15.2.0 and 16.1.0. flang and ifx okay.
gfortran -c reports/gfortran_ice_block_operator.f90
f951: internal compiler error: Segmentation fault
0x22a363f internal_error(char const*, ...)
../../gcc/diagnostic-global-context.cc:787
0xfa48bf crash_signal
../../gcc/toplev.cc:325
0x8508c3 find_symtree0
../../gcc/fortran/interface.cc:4818
0x8508c3 gfc_find_sym_in_symtree(gfc_symbol*)
../../gcc/fortran/interface.cc:4848
0x850f86 gfc_extend_expr(gfc_expr*)
../../gcc/fortran/interface.cc:5140
0x8e23cc resolve_operator
../../gcc/fortran/resolve.cc:4984
0x8e23cc gfc_resolve_expr(gfc_expr*)
../../gcc/fortran/resolve.cc:8253
0x8d33c4 gfc_resolve_expr(gfc_expr*)
../../gcc/fortran/resolve.cc:8231
0x8d33c4 gfc_resolve_code(gfc_code*, gfc_namespace*)
../../gcc/fortran/resolve.cc:14279
0x8d6e3b resolve_codes
../../gcc/fortran/resolve.cc:20423
0x8d6f02 gfc_resolve(gfc_namespace*)
../../gcc/fortran/resolve.cc:20458
0x8d428e gfc_resolve(gfc_namespace*)
../../gcc/fortran/resolve.cc:20446
0x8d428e resolve_block_construct
../../gcc/fortran/resolve.cc:12883
0x8d428e gfc_resolve_code(gfc_code*, gfc_namespace*)
../../gcc/fortran/resolve.cc:14599
0x8d6e3b resolve_codes
../../gcc/fortran/resolve.cc:20423
0x8d6d5e resolve_codes
../../gcc/fortran/resolve.cc:20404
0x8d6f02 gfc_resolve(gfc_namespace*)
../../gcc/fortran/resolve.cc:20458
0x8c132b gfc_parse_file()
../../gcc/fortran/parse.cc:7743
0x92d99f gfc_be_parse_file
../../gcc/fortran/f95-lang.cc:247
/home/opt/gcc-16.1.0/bin/../libexec/gcc/x86_64-pc-linux-gnu/16.1.0/f951
reports/gfortran_ice_block_operator.f90 -quiet -dumpbase
gfortran_ice_block_operator.f90 -dumpbase-ext .f90 -mtune=generic -march=x86-64
-fintrinsic-modules-path
/home/opt/gcc-16.1.0/bin/../lib/gcc/x86_64-pc-linux-gnu/16.1.0/finclude
-fpre-include=/usr/include/finclude/math-vector-fortran.h -o /tmp/ccom1Bnu.s
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.