public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "kargl at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/60148] strings in NAMELIST do not honor DELIM= in open statement
Date: Tue, 11 Feb 2014 16:30:00 -0000 [thread overview]
Message-ID: <bug-60148-4-PePyGTjFPu@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-60148-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60148
kargl at gcc dot gnu.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to fail| |4.7.4, 4.8.3, 4.9.0
--- Comment #1 from kargl at gcc dot gnu.org ---
program namelistout
implicit none
character :: mystring*5 = 'tue'
namelist /mylist/ mystring
open(unit=10,file='junk1.dat',delim='apostrophe')
write(10, mylist)
close(10)
open(unit=10,file='junk2.dat',delim='quote')
write(10, mylist)
close(10)
open(unit=10,file='junk3.dat',delim='none')
write(10, mylist)
close(10)
open(unit=10,file='junk4.dat')
write(10, mylist)
close(10)
end program
% gfc4x -o z g.f90 && ./z
% cat junk?.dat
&MYLIST
MYSTRING='tue ',
/
&MYLIST
MYSTRING="tue ",
/
&MYLIST
MYSTRING="tue ",
/
&MYLIST
MYSTRING="tue ",
/
junk3.dat and junk4.dat should contain
&MYLIST
MYSTRING=tue,
/
10.11.4.2 Namelist output editing
Values in namelist output records are edited as for
list-directed output (10.10.4).
10.10.4
...
Character sequences produced when the delimiter mode has a
value of NONE
. are not delimited by apostrophes or quotation marks,
. are not separated from each other by value separators,
· have each internal apostrophe or quotation mark
represented externally by one apostrophe or quotation
mark, and
· have a blank character inserted by the processor at the
beginning of any record that begins with the continuation
of a character sequence from the preceding record.
Character sequences produced when the delimiter mode has a
value of QUOTE are delimited by quotes, are preceded and
followed by a value separator, and have each internal quote
represented on the external medium by two contiguous quotes.
Character sequences produced when the delimiter mode has a
value of APOSTROPHE are delimited by apostrophes, are preceded
and followed by a value separator, and have each internal
apostrophe represented on the external medium by two contiguous
apostrophes.
9.5.6.8 DELIM= specifier in the OPEN statement
The scalar-default-char-expr shall evaluate to APOSTROPHE, QUOTE,
or NONE. The DELIM= specifier is permitted only for a connection
for formatted input/output. It specifies the delimiter mode
(9.6.2.8) for list-directed (10.10.4) and namelist (10.11.4.2)
output for the connection. This mode has no effect on input. It
is a changeable mode (9.5.2). If this specifier is omitted in an
OPEN statement that initiates a connection, the default value is NONE.
>From gcc-bugs-return-443309-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Feb 11 16:31:48 2014
Return-Path: <gcc-bugs-return-443309-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 5938 invoked by alias); 11 Feb 2014 16:31:48 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 5879 invoked by uid 48); 11 Feb 2014 16:31:41 -0000
From: "ktietz at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/58873] [4.7/4.8/4.9 Regression] [c++11] ICE with __underlying_type for broken enum
Date: Tue, 11 Feb 2014 16:31:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c++
X-Bugzilla-Version: 4.9.0
X-Bugzilla-Keywords: error-recovery, ice-on-invalid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: ktietz at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P5
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: 4.7.4
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields: cc
Message-ID: <bug-58873-4-CHszqsvNlh@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-58873-4@http.gcc.gnu.org/bugzilla/>
References: <bug-58873-4@http.gcc.gnu.org/bugzilla/>
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-02/txt/msg01066.txt.bz2
Content-length: 1080
http://gcc.gnu.org/bugzilla/show_bug.cgi?idX873
Kai Tietz <ktietz at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ktietz at gcc dot gnu.org
--- Comment #2 from Kai Tietz <ktietz at gcc dot gnu.org> ---
Issue here is that the argument type gets NULL for function-call of
cp_parser_functional_cast. This invalid type is the result of
cp_parser_simple_type_specifier call.
A fix might be to checking within cp_parser_functional_cast for type == NULL
and set it to error_mark_node if so.
Index: parser.c
==================================================================--- parser.c (Revision 207686)
+++ parser.c (Arbeitskopie)
@@ -23167,6 +23167,9 @@ cp_parser_functional_cast (cp_parser* parser, tree
tree cast;
bool nonconst_p;
+ if (!type)
+ type = error_mark_node;
+
if (cp_lexer_next_token_is (parser->lexer, CPP_OPEN_BRACE))
{
maybe_warn_cpp0x (CPP0X_INITIALIZER_LISTS);
next prev parent reply other threads:[~2014-02-11 16:30 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-11 16:15 [Bug fortran/60148] New: " kargl at gcc dot gnu.org
2014-02-11 16:30 ` kargl at gcc dot gnu.org [this message]
2014-02-11 18:28 ` [Bug fortran/60148] " dominiq at lps dot ens.fr
2014-02-12 2:34 ` jvdelisle at gcc dot gnu.org
2014-02-12 3:12 ` kargl at gcc dot gnu.org
2014-02-12 5:24 ` sgk at troutmask dot apl.washington.edu
2014-02-13 2:26 ` jvdelisle at gcc dot gnu.org
2014-02-23 19:56 ` jvdelisle at gcc dot gnu.org
2014-02-23 21:07 ` burnus at gcc dot gnu.org
2014-02-26 5:47 ` jvdelisle at gcc dot gnu.org
2014-03-04 4:34 ` jvdelisle at gcc dot gnu.org
2014-03-04 5:46 ` jvdelisle at gcc dot gnu.org
2014-03-08 21:57 ` jvdelisle at gcc dot gnu.org
2014-03-21 22:15 ` jvdelisle at gcc dot gnu.org
2014-03-21 22:20 ` jvdelisle at gcc dot gnu.org
2014-03-21 22:26 ` jvdelisle at gcc dot gnu.org
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-60148-4-PePyGTjFPu@http.gcc.gnu.org/bugzilla/ \
--to=gcc-bugzilla@gcc.gnu.org \
--cc=gcc-bugs@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).