re PR fortran/17615 (Internal compiler error using interface procedures)
fortran/ PR fortran/17615 * trans-expr.c (gfc_trans_arrayfunc_assign): Look at resolved function to determine return type. testsuite/ PR fortran/17615 * gfortran.dg/pr17615.f90: New test. From-SVN: r88061
This commit is contained in:
parent
3d15015ded
commit
c0c07d7b82
@ -3,6 +3,13 @@
|
||||
* trans-types.c (gfc_return_by_reference): Remove superfluous
|
||||
assertion.
|
||||
|
||||
* intrinsic.h (gfc_resolve_getcwd): Update prototype.
|
||||
* iresolve.c (gfc_resolve_getcwd): Add second argument to function.
|
||||
|
||||
PR fortran/17615
|
||||
* trans-expr.c (gfc_trans_arrayfunc_assign): Look at resolved
|
||||
function to determine return type.
|
||||
|
||||
2004-09-20 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
* trans-decl.c (build_entry_thunks): Finalize the function; do not lower
|
||||
|
@ -2007,8 +2007,8 @@ gfc_trans_arrayfunc_assign (gfc_expr * expr1, gfc_expr * expr2)
|
||||
/* The frontend doesn't seem to bother filling in expr->symtree for intrinsic
|
||||
functions. */
|
||||
gcc_assert (expr2->value.function.isym
|
||||
|| (gfc_return_by_reference (expr2->symtree->n.sym)
|
||||
&& expr2->symtree->n.sym->result->attr.dimension));
|
||||
|| (gfc_return_by_reference (expr2->value.function.esym)
|
||||
&& expr2->value.function.esym->result->attr.dimension));
|
||||
|
||||
ss = gfc_walk_expr (expr1);
|
||||
gcc_assert (ss != gfc_ss_terminator);
|
||||
|
@ -1,3 +1,8 @@
|
||||
2004-09-24 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de>
|
||||
|
||||
PR fortran/17615
|
||||
* gfortran.dg/pr17615.f90: New test.
|
||||
|
||||
2004-09-24 Andrew MacLeod <amacleod@redhat.com>
|
||||
|
||||
PR tree-optimzation/17517
|
||||
|
19
gcc/testsuite/gfortran.dg/pr17615.f90
Normal file
19
gcc/testsuite/gfortran.dg/pr17615.f90
Normal file
@ -0,0 +1,19 @@
|
||||
! { dg-do compile }
|
||||
! we didn't look at the right symbol when genrating code. This broke
|
||||
! when array valued functions came into play.
|
||||
module module_vec3d
|
||||
INTERFACE cross_product
|
||||
MODULE PROCEDURE cross_product3_R4_R8
|
||||
END INTERFACE
|
||||
CONTAINS
|
||||
FUNCTION cross_product3_R4_R8 ()
|
||||
real(8) :: cross_product3_r4_r8(3)
|
||||
cross_product3_r4_r8 = 0
|
||||
END FUNCTION cross_product3_R4_R8
|
||||
END MODULE module_vec3d
|
||||
|
||||
PROGRAM TEST
|
||||
use module_vec3d, only: cross_product
|
||||
real(8) :: c(3)
|
||||
c = cross_product()
|
||||
END PROGRAM TEST
|
Loading…
Reference in New Issue
Block a user