Commit 95cb77e6 by Wolfgang Gellerich Committed by Andreas Krebbel

trans-expr.c (gfc_add_interface_mapping): For characters, dereference pointer if…

trans-expr.c (gfc_add_interface_mapping): For characters, dereference pointer if necessary and then perform the cast.

2006-09-13  Wolfgang Gellerich  <gellerich@de.ibm.com>

	* trans-expr.c (gfc_add_interface_mapping): For characters, dereference
	pointer if necessary and then perform the cast.

From-SVN: r116921
parent fcc42bca
2006-09-13 Wolfgang Gellerich <gellerich@de.ibm.com>
* trans-expr.c (gfc_add_interface_mapping): For characters, dereference
pointer if necessary and then perform the cast.
2006-09-11 Steven G. Kargl <kargl@gcc.gnu.org> 2006-09-11 Steven G. Kargl <kargl@gcc.gnu.org>
* intrinsic.c: Update Copyright date. * intrinsic.c: Update Copyright date.
......
...@@ -1386,11 +1386,10 @@ gfc_add_interface_mapping (gfc_interface_mapping * mapping, ...@@ -1386,11 +1386,10 @@ gfc_add_interface_mapping (gfc_interface_mapping * mapping,
tmp = gfc_get_character_type_len (sym->ts.kind, NULL); tmp = gfc_get_character_type_len (sym->ts.kind, NULL);
tmp = build_pointer_type (tmp); tmp = build_pointer_type (tmp);
if (sym->attr.pointer) if (sym->attr.pointer)
tmp = build_pointer_type (tmp); value = build_fold_indirect_ref (se->expr);
else
value = fold_convert (tmp, se->expr); value = se->expr;
if (sym->attr.pointer) value = fold_convert (tmp, value);
value = build_fold_indirect_ref (value);
} }
/* If the argument is a scalar, a pointer to an array or an allocatable, /* If the argument is a scalar, a pointer to an array or an allocatable,
......
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