This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/38823] Diagnose and treat (-2.0)**2.0 properly
- From: "dominiq at lps dot ens dot fr" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 13 Jan 2009 11:37:25 -0000
- Subject: [Bug fortran/38823] Diagnose and treat (-2.0)**2.0 properly
- References: <bug-38823-13404@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- 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