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/29441] non-constant parameter (constant) accepted



------- Comment #2 from pinskia at gcc dot gnu dot org  2006-10-12 15:12 -------
Actually adding -pedantic, and this is rejected:
 In file t.f90:3

  real, parameter :: pi = 4.0*atan(1.0)
                                 1
Error: Extension: Evaluation of nonstandard initialization expression at (1)

And has since 4.0.3:
[pinskia@celery ~]$ ~/gcc-4.0/bin/gfortran t.f90 -std=f95 -pedantic-errors
 In file t.f90:3

  real, parameter :: pi = 4.0*atan(1.0)
                                 1
Error: Extension: Evaluation of nonstandard initialization expression at (1)
[pinskia@celery ~]$ ~/gcc-4.1/bin/gfortran t.f90 -std=f95 -pedantic-errors
 In file t.f90:3

  real, parameter :: pi = 4.0*atan(1.0)
                                 1
Error: Extension: Evaluation of nonstandard initialization expression at (1)


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to fail|4.2.0                       |


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


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