[Bug fortran/61910] undefined computation in trans-expr.c gfc_conv_cst_int_power
mpolacek at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Sep 4 10:13:00 GMT 2014
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61910
Marek Polacek <mpolacek at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|WAITING |NEW
CC| |mpolacek at gcc dot gnu.org
Target Milestone|--- |4.9.2
--- Comment #4 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Ok, I managed to whip up a complete testcase:
program test
integer i
integer j
j=i**(-huge(0_8)-1)
end program test
on this I see
$ ./xgcc -B./ -c x.f90
/home/polacek/src/gcc/gcc/fortran/trans-expr.c:2286:48: runtime error: negation
of -9223372036854775808 cannot be represented in type 'long int [3]'; cast to
an unsigned type to negate this value to itself
So confirmed.
More information about the Gcc-bugs
mailing list