+2015-05-18 Steven G. Kargl <kargl@gcc.gnu.org>
+
+ PR fortran/64925
+ * symbol.c(check_conflict): Check for a conflict between a dummy
+ argument and an internal procedure name.
+
2015-05-16 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/65903
}
}
+ if (attr->dummy && ((attr->function || attr->subroutine) &&
+ gfc_current_state () == COMP_CONTAINS))
+ gfc_error_now ("internal procedure '%s' at %L conflicts with "
+ "DUMMY argument", name, where);
+
conf (dummy, entry);
conf (dummy, intrinsic);
conf (dummy, threadprivate);
+2015-05-18 Steven G. Kargl <kargl@gcc.gnu.org>
+
+ PR fortran/64925
+ * gfortran.dg/pr64925.f90: New test.
+
2015-05-18 Steven G. Kargl <kargl@gcc.gnu.org>
* gfortran.dg/lto/pr41521_0.f90: Move INTERFACE statement in program
--- /dev/null
+! { dg-do compile }
+! PR fortran/64925
+! Original test case provided by Bill Long <longb at cray dot com>
+!
+subroutine foo(nnn, aaa, bbb, ccc, ddd)
+ implicit none
+ integer :: nnn, aaa, bbb(nnn)
+ integer :: i
+ do i=1,nnn
+ aaa = aaa + bbb(ccc(i))
+ end do
+ call ddd(aaa)
+contains
+ integer function ccc(i) ! { dg-error "conflicts with DUMMY" }
+ integer :: i
+ ccc = i
+ end function ccc
+ subroutine ddd(j) ! { dg-error "conflicts with DUMMY" }
+ integer j
+ j = j + 1
+ end subroutine ddd
+end subroutine foo