diff options
author | Paul Thomas <pault@gcc.gnu.org> | 2008-11-16 12:00:44 +0000 |
---|---|---|
committer | Paul Thomas <pault@gcc.gnu.org> | 2008-11-16 12:00:44 +0000 |
commit | b800fd64b54018965f6953121b58673fcca08687 (patch) | |
tree | c2fcc0b76322c1e52d199636a9de594873b232d5 /gcc/fortran/trans-expr.c | |
parent | e66e5d9e4079b7a44fcdd963838218812cfb534e (diff) | |
download | gcc-b800fd64b54018965f6953121b58673fcca08687.zip gcc-b800fd64b54018965f6953121b58673fcca08687.tar.gz gcc-b800fd64b54018965f6953121b58673fcca08687.tar.bz2 |
re PR fortran/37926 (Program gives wrong output (connected to char len))
2008-11-16 Paul Thomas <pault@gcc.gnu.org>
PR fortran/37926
* trans-expr.c (gfc_free_interface_mapping): Null sym->formal
(gfc_add_interface_mapping): Copy the pointer to the formal
arglist, rather than using copy_formal_args.
From-SVN: r141914
Diffstat (limited to 'gcc/fortran/trans-expr.c')
-rw-r--r-- | gcc/fortran/trans-expr.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/fortran/trans-expr.c b/gcc/fortran/trans-expr.c index ff74928d..2e148f2c 100644 --- a/gcc/fortran/trans-expr.c +++ b/gcc/fortran/trans-expr.c @@ -1583,6 +1583,7 @@ gfc_free_interface_mapping (gfc_interface_mapping * mapping) for (sym = mapping->syms; sym; sym = nextsym) { nextsym = sym->next; + sym->new_sym->n.sym->formal = NULL; gfc_free_symbol (sym->new_sym->n.sym); gfc_free_expr (sym->expr); gfc_free (sym->new_sym); @@ -1715,7 +1716,7 @@ gfc_add_interface_mapping (gfc_interface_mapping * mapping, descriptors are passed for array actual arguments. */ if (sym->attr.flavor == FL_PROCEDURE) { - copy_formal_args (new_sym, expr->symtree->n.sym); + new_sym->formal = expr->symtree->n.sym->formal; new_sym->attr.always_explicit = expr->symtree->n.sym->attr.always_explicit; } |