Commit c1db9545 by Janus Weil

re PR fortran/36459 (Wrong interface use for PROCEDURE)

2008-06-08  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/36459
	* decl.c (match_procedure_decl): Correctly recognize if the interface
	is an intrinsic procedure.


2008-06-08  Janus Weil  <janus@gcc.gnu.org>

	PR fortran/36459
	* gfortran.dg/proc_decl_16.f90: New.

From-SVN: r136555
parent 2d9bbb6b
2008-06-08 Janus Weil <janus@gcc.gnu.org>
PR fortran/36459
* decl.c (match_procedure_decl): Correctly recognize if the interface
is an intrinsic procedure.
2008-06-08 Tobias Burnus <burnus@net-b.de>
PR fortran/35830
......
......@@ -4085,8 +4085,10 @@ match_procedure_decl (void)
return MATCH_ERROR;
}
/* Handle intrinsic procedures. */
if (gfc_intrinsic_name (proc_if->name, 0)
|| gfc_intrinsic_name (proc_if->name, 1))
if (!(proc_if->attr.external || proc_if->attr.use_assoc
|| proc_if->attr.if_source == IFSRC_IFBODY)
&& (gfc_intrinsic_name (proc_if->name, 0)
|| gfc_intrinsic_name (proc_if->name, 1)))
proc_if->attr.intrinsic = 1;
if (proc_if->attr.intrinsic
&& !gfc_intrinsic_actual_ok (proc_if->name, 0))
......
2008-06-08 Janus Weil <janus@gcc.gnu.org>
PR fortran/36459
* gfortran.dg/proc_decl_16.f90: New.
2008-06-08 Tobias Burnus <burnus@net-b.de>
PR fortran/35830
......
! { dg-do compile }
! PR fortran/36459
!
abstract interface
function dim()
integer :: dim
end function dim
end interface
procedure(dim) :: f
interface
integer function tan()
end function
end interface
procedure(tan) :: g
print *, f()
print *, tan()
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment