I am using flang-new 19.0. With the following Fortran code
! test_overflow.f90
program test_overflow
implicit none
print *, range(0.0)
print *, 10.0**(-32.0)
print *, 10.0**(-32)
end program test_overflow
I got the following:
$ uname -a && flang-new --version && flang-new test_overflow.f90 && ./a.out
Linux 6.5.0-26-generic #26~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Mar 12 10:22:43 UTC 2 x86_64 x86_64 x86_64 GNU/Linux
flang-new version 19.0.0git (git@github.com:llvm/llvm-project.git 37c175af955f0aeab67e8c553a0a47b2ed0fdba2)
Target: x86_64-unknown-linux-gnu
Thread model: posix
./test_overflow.f90:6:10: warning: overflow on power with INTEGER exponent
print *, 10.0**(-32)
^^^^^^^^^^^
37
1.E-32
9.9999995E-33
Note that print *, 10.0**(-32)
leads to an “overflow on power with INTEGER exponent”.
What is overflowing? Is this expected or a false positive?
Thanks.