------- Comment #9 from burnus at gcc dot gnu dot org 2009-06-24 18:11 ------- > > It would be nice to have an option to turn off that fast inversion, at least > > for compatibility. Or at least to make -O0 case compatible. > How do other vendor's (Sun, Pathscale, Absoft, etc) represent .true. > and .false.? Do we need a compatibility option for each vendor?
Well, I think handling "! boolean" as "! (int) boolean" is enough, i.e. converting all booleans to integer as C has for integers the concept of nonzero = true and zero = false - thus NOT(nonzero) is alway zero (all bits). I think one can consider such an option, but I am not really happy about such a solution - and I think (fear?) others will (strongly) oppose such an option. Regarding the rhetoric question: NAG f95, sunf95 and g95 use 1 and 0; using ifort + Intel's icc, open64's opencc, Sun's suncc, however, gives FALSE for when using NOT ("!") on the result of the Fortran function call. (With GCC it gives TRUE.) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40539