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

compiler error detection

soree
Beginner
508 Views
I use the compiler ifc8.1 with the -O2 -c -ttp7 -r8 options
and it seems that it is not able to detect some errors in my
code. For example writing a function k_0(a,b) as k_0 or making an array too small, i.e. declaring an array of dimension 2 while
calling the value of array(3) somewhere else doesnt invoke
an error? Do I have to set more options or is it something else ?
0 Kudos
1 Reply
TimP
Honored Contributor III
508 Views
If you had k_0(a,b) and k_0 in the same subroutine, there should be an error. Otherwise, you might get checking by defining k_0 as a CONTAINS or MODULE function, or providing an INTERFACE block.

There are possibilities going way back in Fortran about accessing a multiple dimension array with a single subscript, which might give your mistake a standard meaning.
0 Kudos
Reply