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/38823] Diagnose and treat (-2.0)**2.0 properly



------- Comment #3 from dominiq at lps dot ens dot fr  2009-01-13 11:37 -------
> - Mathematica:
>   -2^2 = 4, -2.0^2.0 = -4.0
>   2.0^1.9 = -3.73213      <------- probably -2.0^1.9!

Apparently Mathematica parse "-2.0^a" as "-(2.0^a)". (-2.0)^1.9 gives "3.54947-
1.15329 I". I don't know if the fortran standard says how "-a**b" should be
parsed (nor have the time right now to decipher the legalese).


-- 


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


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