Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
Welcome to the Intel Community. If you get an answer you like, please mark it as an Accepted Solution to help others. Thank you!
26729 Discussions

error not detected unless -warn all is given

warpino
Beginner
105 Views

Hi all,

I am debugging a friend's code. At some point he calls a subroutine with the wrong number of arguments, actually he gives more actual arguments than dummy ones. I didn't spot the error until I used the -warn all option to compile. Is this the expected behaviour?

Using Intel Fortran Compiler for Intel64, Version 15 on Linux CentOS 6

 

Thanks in advance,

 

NL

 

0 Kudos
1 Reply
jimdempseyatthecove
Black Belt
105 Views

The -warn all option generates interfaces and checks interfaces. The Fortran compiler cannot verify calling arguments for subroutines and functions that do not have/use interfaces. Subroutines and functions contained in modules have interfaces by default, Those non-module subroutines and functions do not have interfaces (though some checking could potentially be performed in the IPO phase).

Jim Dempsey

Reply