From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6730 invoked by alias); 10 Jan 2014 22:31:38 -0000 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 Received: (qmail 6694 invoked by uid 48); 10 Jan 2014 22:31:35 -0000 From: "jvdelisle at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libfortran/59764] Read logicals, line buffer, item_count, and error message consistancy Date: Fri, 10 Jan 2014 22:31:00 -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: 4.9.0 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: normal X-Bugzilla-Who: jvdelisle at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: jvdelisle 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: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-01/txt/msg01199.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59764 --- Comment #3 from Jerry DeLisle --- I have a patch successfully regression tested. Basically, I have change in io.h as follows. The component expanded_read is just a flag and does not need to an integer, so I have used an available bit above it for this and and then used the integer slot for line_buffer_pos. This integer is then used in those places where needed for the look-ahead buffer. I will submit a patch for approval as soon as I get coordinated with Steves patch for pr59700. Index: io.h =================================================================== --- io.h (revision 206351) +++ io.h (working copy) @@ -430,7 +430,10 @@ unsigned g0_no_blanks : 1; /* Used to signal use of free_format_data. */ unsigned format_not_saved : 1; - /* 14 unused bits. */ + /* A flag used to identify when a non-standard expanded namelist read + has occurred. */ + unsigned expanded_read : 1; + /* 13 unused bits. */ /* Used for ungetc() style functionality. Possible values are an unsigned char, EOF, or EOF - 1 used to mark the @@ -447,9 +450,8 @@ char *line_buffer; struct format_data *fmt; namelist_info *ionml; - /* A flag used to identify when a non-standard expanded namelist read - has occurred. */ - int expanded_read; + /* Current position within the look-ahead line buffer. */ + int line_buffer_pos; /* Storage area for values except for strings. Must be large enough to hold a complex value (two reals) of the largest kind. */