public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/35009]  New: error on valid with -std=f95 (character arrays in format tags)
@ 2008-01-29  5:40 bcbarnes at gmail dot com
  2008-01-29 12:34 ` [Bug fortran/35009] " fxcoudert at gcc dot gnu dot org
                   ` (14 more replies)
  0 siblings, 15 replies; 16+ messages in thread
From: bcbarnes at gmail dot com @ 2008-01-29  5:40 UTC (permalink / raw)
  To: gcc-bugs

from my original report:

I have a program which uses conditional format tags, similar to this testcase
which is taken from page 187 of Metcalf, Reid and Cohen's Fortran 95/2003
explained:

---
      program testcase
      integer :: ival(30),key,i
      character(30) :: buffer
      character(6) :: form2(3) = (/ '(30i1)', '(15i2)', '(10i3)' /)

      read (*, '(a30,i1)') buffer, key
      read (buffer, form2 (key)) (ival(i), i=1,30/key)

      end
---

When compiled with -std=gnu  (gfortran 4.2.2, darwin8), no warning is issued
(which is good).  But when compiled with -std=f95 or -std=f2003, the following
error results:

---
nell:~/work/bit barnes$ gfortran -std=f95 testcase.f
testcase.f:7.19:

      read (buffer, form2 (key)) (ival(i), i=1,30/key)
                  1
Error: Extension: Character array in FORMAT tag at (1)
---


Tobias S. confirmed this as a bug.  I was using gfortran 4.2.2 but this is
probably in 4.3.0 as well.


-- 
           Summary: error on valid with -std=f95 (character arrays in format
                    tags)
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: bcbarnes at gmail dot com


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35009


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2009-10-05  2:49 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-01-29  5:40 [Bug fortran/35009] New: error on valid with -std=f95 (character arrays in format tags) bcbarnes at gmail dot com
2008-01-29 12:34 ` [Bug fortran/35009] " fxcoudert at gcc dot gnu dot org
2008-02-04 23:15 ` fxcoudert at gcc dot gnu dot org
2008-02-09  6:15 ` pault at gcc dot gnu dot org
2008-02-13  5:42 ` jvdelisle at gcc dot gnu dot org
2008-02-13  6:10 ` jvdelisle at gcc dot gnu dot org
2008-02-13  8:59 ` fxcoudert at gcc dot gnu dot org
2008-02-28 23:09 ` fxcoudert at gcc dot gnu dot org
2008-02-29  4:53 ` jvdelisle at gcc dot gnu dot org
2008-03-02 22:31 ` fxcoudert at gcc dot gnu dot org
2008-03-02 23:07 ` jvdelisle at gcc dot gnu dot org
2008-03-13  5:14 ` jvdelisle at gcc dot gnu dot org
2009-01-03 22:38 ` dfranke at gcc dot gnu dot org
2009-01-04  6:08 ` jvdelisle at gcc dot gnu dot org
2009-10-04 21:18 ` jvdelisle at gcc dot gnu dot org
2009-10-05  2:49 ` jvdelisle at gcc dot gnu dot org

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).