Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Intel 16 Giving #8763 warnings

Zukaitis__Anthony
457 Views

Is this right?  Didn't have this problem with earlier versions....

data (arr(i),i=1,2) /-4.00e+00_dknd, -3.600e+00_dknd/

 

0 Kudos
4 Replies
Steven_L_Intel1
Employee
457 Views

We need a bit more context - ideally a small but complete program that shows the problem. Also, just giving the error number isn't sufficient - we need to see the actual and complete message.

0 Kudos
Zukaitis__Anthony
457 Views

Ok here's more detail

program main
   integer, parameter :: dknd  = selected_real_kind(15,307)   != 8-byte realkind
   real(dknd) arr(2)
   data (arr(i),i=1,2) /-4.00e+00_dknd, -3.600e+00_dknd/
end program

ifort ./main.f90  -stand f03
./main.f90(4): warning #8763: Fortran 2003 does not allow an expression as a DATA statement constant.
   data (arr(i),i=1,2) /-4.00e+00_dknd, -3.600e+00_dknd/
-------------------------^
./main.f90(4): warning #8763: Fortran 2003 does not allow an expression as a DATA statement constant.
   data (arr(i),i=1,2) /-4.00e+00_dknd, -3.600e+00_dknd/

ifort 15.0.5.223 does not give the warning but ifort 16.0.3.210 give it.

 

This is on Linux

 

 

0 Kudos
Steven_L_Intel1
Employee
457 Views

Fascinating. Definitely a compiler bug. This is just a standards warning so you can either not specify -std or disable it with -diag-disable=8763

I will report this to development to be fixed in a future release. Issue ID DPD200412104.

0 Kudos
Steven_L_Intel1
Employee
457 Views

I expect this to be fixed in version 17.

0 Kudos
Reply