From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2572 invoked by alias); 23 Sep 2012 16:24:34 -0000 Received: (qmail 2532 invoked by uid 48); 23 Sep 2012 16:24:02 -0000 From: "kargl at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/54679] Erroneous "Expected P edit descriptor" in conjunction with L descriptor Date: Sun, 23 Sep 2012 16:24:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Keywords: X-Bugzilla-Severity: trivial X-Bugzilla-Who: kargl at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P5 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Priority CC Severity Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-09/txt/msg01843.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54679 kargl at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P3 |P5 CC| |kargl at gcc dot gnu.org Severity|normal |trivial --- Comment #2 from kargl at gcc dot gnu.org 2012-09-23 16:24:01 UTC --- (In reply to comment #1) > Please reduce the severity to trivial, and change it to "Confusing > diagnostic"! It's my error, at root, but gfortran could do better. > > I had forgotten the relevant constraint (C1006 in Fortran 2003). > However, the syntax rule R1005 on the same page specifies that a > width is mandatory for the L descriptor, so the actual error is > that a width of zero is erroneous. I agree that the error message is confusing. First, the F2008 constraint is C1006 (R1008) w shall be zero or positive for the I, B, O, Z, F, and G edit descriptors. w shall be positive for all other edit descriptors. Second, we have 10.8.5 P editing The k P edit descriptor temporarily changes (9.5.2) the scale factor for the connection to k . The scale factor affects the editing done by the F, E, EN, ES, D, and G edit descriptors for numeric quantities. So P editing does not even apply to the L descriptor.