From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 533F13858CD1; Mon, 11 Mar 2024 16:25:16 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 533F13858CD1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1710174316; bh=fsfmTJzh+f+NewRhB8av5ddq25CMV97gK7ZpoNNxhts=; h=From:To:Subject:Date:From; b=tvSXSo3HwxBJ1jRI/faRqoe6kCcasH0X22sjlEICEo7gHPbgHWs6opwMTMqT/4pyB 7gju0uN8aeAdl0woEu7EotEXAUVByYGqxQzB1fV0YUByMJQusM5bY8YBy4Sn7Dh3x7 1kUVBE1RYJPijgjMKweijUtbu4RKPF/ucagc8w/Q= From: "asiancorporator at yahoo dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/114308] New: ICE in fold_convert_loc, at fold-const.cc:2627 Date: Mon, 11 Mar 2024 16:25:15 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 13.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: asiancorporator at yahoo dot de X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D114308 Bug ID: 114308 Summary: ICE in fold_convert_loc, at fold-const.cc:2627 Product: gcc Version: 13.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: asiancorporator at yahoo dot de Target Milestone: --- I am getting an error when I tried to extend an array that is supposed to contain instances inherited from abstract classes. Ran on macOS Sonoma 14.2= .1 (M1) with gfortran 13.2.1. module my_module implicit none private type, abstract, public :: a end type type, extends(a), public :: b end type end program main use my_module implicit none class(a), allocatable :: a_array(:) type(b) :: b_instance a_array =3D [b_instance] ! This line works a_array =3D [a_array, b_instance] ! This one throws an ICE end program Output: main.f90 failed. [ 50%] Compiling... app/main.f90:20:58: 20 | a_array =3D [a_array, b_instance] ! This one throws an ICE | 1 internal compiler error: in fold_convert_loc, at fold-const.cc:2627 Please submit a full bug report, with preprocessed source (by using -freport-bug). See for instructions. Compilation failed for object " app_main.f90.o " stopping due to failed compilation STOP 1=