This is the mail archive of the gcc@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]

Re: g77 compiles illegal code in testsuite?


Steven G. Kargl wrote:

Bud Davis said:


| I'm running the Fortran 77 code in gcc-testsuite-3.3.tar.bz2
| through g95 and I've found that 20000601-2.f contains
| illegal code for Fortran 95 and probably Fortran 77. I don't
| have the Fortran 77 standard handy, but I believe the code is
| illegal; yet g77 compiles the code without warning or error.





[Table of intrinsics snipped]




In my interpretation, the code in question is not valid.
MAX is the generic name for MAX0,AMAX1, and DMAX1,



This is correct.




not for AMAX0 which is the specfic intrinisic needed here.



Actually, I beleive AMAX0 would also be wrong. The arguments of AMAX0 must have the same type.



Maybe g77 should issue a warning (when invoked with -fpedantic) ?




It's Toon's call, but I think g77 should issue an error and abort. The g77 info contains a -fno-ugly-args option. I would think you should need -fugly-args to compile the code in question.



Of course, IMHO, g95 should be backwards compatable with g77 :)



This may not happen, because Fortran 95 has deleted a few features from Fortran 77.




quite right about AMAX0. it would not be correct. i read the table wrong :)





--bud davis




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