From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 09639385741C; Tue, 17 May 2022 19:56:19 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 09639385741C From: "anlauf 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: Tue, 17 May 2022 19:56:18 +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: anlauf 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: 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: Tue, 17 May 2022 19:56:19 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105243 --- Comment #7 from anlauf at gcc dot gnu.org --- (In reply to Steve Kargl from comment #6) > > I quoted the F2018 standard constraint. > >=20 > > C708 An entity declared with the CLASS keyword shall be a dummy > > argument or have the ALLOCATABLE or POINTER attribute. > >=20 > > class(t), parameter :: y > >=20 > > would seem to be missing all of the three listed attributes. You're right here. > I'll also add=20 >=20 > 7.3.2.3 CLASS type specifier >=20 > The CLASS type specifier is used to declare polymorphic entities. > A polymorphic entity is a data entity that is able to be of differing > dynamic types during program execution. >=20 > Does is make sense to given a named constant the polymorphic property? Well, I could imagine named constants that do not have a type (e.g. when using CLASS(*)), as well as named constants that refer to an extensible type. The F2023 draft even has CLASSOF. Where will this finally lead... I think I should ask the Intel people why their compiler accepts program p type t integer :: i =3D 1 end type t type(t), parameter :: a =3D t() ! Legal class(t), parameter :: b =3D t() ! Likely not class(*), parameter :: c =3D t() ! ... class(*), parameter :: d =3D 1 ! ... end=