]> git.ipfire.org Git - thirdparty/gcc.git/commit
re PR fortran/41139 (a procedure pointer call as actual argument)
authorJanus Weil <janus@gcc.gnu.org>
Tue, 25 Aug 2009 14:26:44 +0000 (16:26 +0200)
committerJanus Weil <janus@gcc.gnu.org>
Tue, 25 Aug 2009 14:26:44 +0000 (16:26 +0200)
commit23878536a6b359865599d300c214bbb8fef83a43
tree3af99476a57f873526e5deb43b0c56abfcee584b
parent4df62c77fe216dd68b85f09d20910203e035efb2
re PR fortran/41139 (a procedure pointer call as actual argument)

2009-08-25  Janus Weil  <janus@gcc.gnu.org>

PR fortran/41139
* primary.c (gfc_match_varspec): Make sure EXPR_PPC is only used for
calls to procedure pointer components, other references to procedure
pointer components are EXPR_VARIABLE.
* resolve.c (resolve_actual_arglist): Bugfix (there can be calls without
actual arglist).
* trans-expr.c (gfc_get_proc_ptr_comp): Renamed to 'get_proc_ptr_comp',
removed argument 'se' and made static. Avoid inserting a temporary
variable for calling the PPC.
(conv_function_val): Renamed gfc_get_proc_ptr_comp.
(gfc_conv_procedure_call): Distinguish functions returning a procedure
pointer from calls to a procedure pointer. Distinguish calls to
procedure pointer components from procedure pointer components as
actual arguments.
* trans-stmt.h (gfc_get_proc_ptr_comp): Make it static.

2009-08-25  Janus Weil  <janus@gcc.gnu.org>

PR fortran/41139
* gfortran.dg/proc_ptr_25.f90: New.
* gfortran.dg/proc_ptr_comp_18.f90: New.
* gfortran.dg/proc_ptr_comp_19.f90: New.

From-SVN: r151081
gcc/fortran/ChangeLog
gcc/fortran/primary.c
gcc/fortran/resolve.c
gcc/fortran/trans-expr.c
gcc/fortran/trans-stmt.h
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/proc_ptr_25.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/proc_ptr_comp_18.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/proc_ptr_comp_19.f90 [new file with mode: 0644]