This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/25057] default initialization and DATA statement conflict



------- Comment #1 from fxcoudert at gcc dot gnu dot org  2005-11-26 19:24 -------
We currently have an ICE on that one:

## gfortran ##
foo.f90:0: internal compiler error: in gfc_assign_data_value, at
fortran/data.c:252

## g95 ##
In file foo.f90:5

DATA (D(I),I=1,2) /T1(3),T1(3)/
       1
Error: Variable 'd' which has a default initialization cannot appear in a DATA
statement at (1)
## Intel ##
## Portland ##
PGF90-W-0164-Overlapping data initializations of d (foo.f90)
  0 inform,   1 warnings,   0 severes, 0 fatal for MAIN
## Sun ##

DATA (D(I),I=1,2) /T1(3),T1(3)/
      ^
"foo.f90", Line = 5, Column = 7: ERROR: "D" must not be specified in a DATA
statement.  It is typed as derived type "T1", which is default initialized.


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
           Keywords|                            |ice-on-invalid-code
   Last reconfirmed|0000-00-00 00:00:00         |2005-11-26 19:24:21
               date|                            |
            Summary|better diagnostic needed    |default initialization and
                   |                            |DATA statement conflict


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]