From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 89BE53857C42; Wed, 28 Sep 2022 18:23:32 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 89BE53857C42 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1664389412; bh=iskSus67E/oICrlpFEAu/Z8yyLgQpahcDVIOe7NNTBI=; h=From:To:Subject:Date:In-Reply-To:References:From; b=BEAZTeEc4t0np9G97p7diah8E9FM/e4ZiHKFw15SUUMQQC5I0ZVPhg8mhcW53HG7U icwUOCGXqvkY+S0twdjkNPYi5PPdYjn4hPpGoludWW6CVdZ3X9fhyVJ6xI+c7nKXxQ pPIehnMFqsOE8nhvx/LanBbm6jL1Jgy1WoieKH/o= From: "anlauf at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libfortran/107068] Run-time error when reading logical arrays with a namelist Date: Wed, 28 Sep 2022 18:23:32 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libfortran X-Bugzilla-Version: 11.2.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: anlauf at gcc dot gnu.org X-Bugzilla-Status: NEW 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: keywords bug_status everconfirmed component cf_reconfirmed_on 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D107068 anlauf at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |wrong-code Status|UNCONFIRMED |NEW Ever confirmed|0 |1 Component|fortran |libfortran Last reconfirmed| |2022-09-28 --- Comment #2 from anlauf at gcc dot gnu.org --- Confirmed. Renaming the second variable (e.g. flp -> xlp) works around the problem, as well as interchanging the lines in the namelist input. It appears that while scanning the namelist input we first see the T, then F, for which we try to determine if it means .false. or is part of a variable name, and then possibly screw up because we see a comma when referring to an element of rank-2 array flp. There is also no error when using a rank-1 array for flp and referring to flp(2) etc.=