-fugly-logint ?
Tom Roche
Tom_Roche@pobox.com
Sun Nov 27 21:10:00 GMT 2011
Tom Roche Sun, 27 Nov 2011 15:33:18 -0500
>> > foo.f -o foo.o
>> > foo.f:780.10:
>> > IF (LIMIT_Sg == .TRUE.) THEN
>> > 1
>> > Error: Logicals at (1) must be compared with .eqv. instead of ==
>> Can I fix this error without fixing [this legacy] code? E.g., can
>> one compile with something like -fugly-logint
Steve Kargl Sun, 27 Nov 2011 12:38:00 -0800
> You can try -std=legacy.
Looked promising, but didn't fix the error, so ...
> The best option is to fix the code.
$ find /path/to/src -type f | xargs fgrep -le '== .TRUE.' | xargs sed -i 's/== .TRUE./.eqv. .TRUE./g'
(and
$ find /path/to/src -type f | xargs fgrep -le '== .FALSE.' | xargs sed -i 's/== .FALSE./.eqv. .FALSE./g'
for completeness), and now it builds. Hope they'll thank me later :-)
your assistance is appreciated, Tom Roche <Tom_Roche@pobox.com>
More information about the Fortran
mailing list