aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/expr.c
diff options
context:
space:
mode:
authorJanus Weil <janus@gcc.gnu.org>2009-04-28 11:44:36 +0200
committerJanus Weil <janus@gcc.gnu.org>2009-04-28 11:44:36 +0200
commit6596e2fe5a8a24d62431577ef3c9c8e67682f9a3 (patch)
tree0e226dd19b9aac453a4b0f078d25ecebc8d096e2 /gcc/fortran/expr.c
parenta6524a7cb87acd44fe46ad544292708f2d85be52 (diff)
downloadgcc-6596e2fe5a8a24d62431577ef3c9c8e67682f9a3.zip
gcc-6596e2fe5a8a24d62431577ef3c9c8e67682f9a3.tar.gz
gcc-6596e2fe5a8a24d62431577ef3c9c8e67682f9a3.tar.bz2
re PR fortran/39930 (Bogus error: ambiguous reference)
2009-04-28 Janus Weil <janus@gcc.gnu.org> PR fortran/39930 PR fortran/39931 * expr.c (gfc_check_pointer_assign): Correctly detect if the left hand side is a pointer. * parse.c (gfc_fixup_sibling_symbols): Don't check for ambiguity. 2009-04-28 Janus Weil <janus@gcc.gnu.org> PR fortran/39930 PR fortran/39931 * gfortran.dg/ambiguous_reference_2.f90: New. * gfortran.dg/pointer_assign_7.f90: New. From-SVN: r146880
Diffstat (limited to 'gcc/fortran/expr.c')
-rw-r--r--gcc/fortran/expr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/fortran/expr.c b/gcc/fortran/expr.c
index c70d4d1..e76197e 100644
--- a/gcc/fortran/expr.c
+++ b/gcc/fortran/expr.c
@@ -3070,8 +3070,8 @@ gfc_check_pointer_assign (gfc_expr *lvalue, gfc_expr *rvalue)
if (pointer)
check_intent_in = 0;
- if (ref->type == REF_COMPONENT && ref->u.c.component->attr.pointer)
- pointer = 1;
+ if (ref->type == REF_COMPONENT)
+ pointer = ref->u.c.component->attr.pointer;
if (ref->type == REF_ARRAY && ref->next == NULL)
{