From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 767423858C50; Mon, 16 May 2022 00:06:14 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 767423858C50 From: "kargl at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/105243] ICE in next_char, at fortran/io.cc:160 Date: Mon, 16 May 2022 00:06:14 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: ice-on-invalid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: kargl at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P4 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status cf_reconfirmed_on priority cc everconfirmed Message-ID: In-Reply-To: References: 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 May 2022 00:06:14 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105243 kargl at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2022-05-16 Priority|P3 |P4 CC| |kargl at gcc dot gnu.org Ever confirmed|0 |1 --- Comment #2 from kargl at gcc dot gnu.org --- This fixes the problem. Someone that regularly use git will need to commit= it. diff --git a/gcc/fortran/decl.cc b/gcc/fortran/decl.cc index bd586e75008..6712efd6ec8 100644 --- a/gcc/fortran/decl.cc +++ b/gcc/fortran/decl.cc @@ -6283,6 +6283,15 @@ gfc_match_data_decl (void) goto cleanup; } + /* F2018:C708. */ + if (current_ts.type =3D=3D BT_CLASS && current_attr.flavor =3D=3D FL_PAR= AMETER) + { + gfc_error ("CLASS entity at %C shall be a dummy argument or have the= " + "ALLOCATABLE or POINTER attribute."); + m =3D MATCH_ERROR; + goto cleanup; + } + ok: /* If we have an old-style character declaration, and no new-style attribute specifications, then there a comma is optional between=