Hi, the following (incorrect) code gives a misleading error message when compiling:
program gfcbug24 implicit none interface foo subroutine foo_8 (a, b) real (kind(1.d0)) :: a, b end subroutine foo_8 end interface real (kind(1.d0)) :: c = 1.d0 ! gfortran gives a misleading error message for the following line: call foo (c, 2.0) end % gfortran gfcbug24.f90 In file gfcbug24.f90:13 call foo (c, 2.0) 1 Error: Generic subroutine 'foo' at (1) is not an intrinsic subroutine This is misleading. There simply is no specific subroutine whose characteristics matches the (ranks and) types used in the invocation. E.g., the Intel compiler v8.1 says: fortcom: Error: gfcbug24.f90, line 13: There is no matching specific subroutine for this generic subroutine call. [FOO] call foo (c, 2.0) -----^ compilation aborted for gfcbug24.f90 (code 1) Cheers, -ha -- Summary: gfortran: misleading error message resolving generic subroutine Product: gcc Version: 4.0.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: fortran AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: anlauf at hep dot tu-darmstadt dot de CC: gcc-bugs at gcc dot gnu dot org GCC host triplet: i686-pc-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20067