aboutsummaryrefslogtreecommitdiff
path: root/gcc/java
diff options
context:
space:
mode:
authorAlexandre Petit-Bianco <apbianco@cygnus.com>1999-10-22 06:06:47 +0000
committerAlexandre Petit-Bianco <apbianco@gcc.gnu.org>1999-10-21 23:06:47 -0700
commitac22f9cb2c6f5be8f183df71fd783fed1046d309 (patch)
treef42c2d32746219f142f17fa8c955764f747d782a /gcc/java
parent100f7cd8b9ea79bfef97fe723e220711c3e43385 (diff)
downloadgcc-ac22f9cb2c6f5be8f183df71fd783fed1046d309.zip
gcc-ac22f9cb2c6f5be8f183df71fd783fed1046d309.tar.gz
gcc-ac22f9cb2c6f5be8f183df71fd783fed1046d309.tar.bz2
re GNATS gcj/56 (gcj segfaults in jc1 on OK java file)
Thu Oct 21 01:27:31 1999 Alexandre Petit-Bianco <apbianco@cygnus.com> * parse.y (resolve_qualified_expression_name): Handle MODIFY_EXPR. (qualify_ambiguous_name): Likewise. This fixes the net PR #56 (http://sourceware.cygnus.com/ml/java-prs/1999-q3/msg00131.html) From-SVN: r30127
Diffstat (limited to 'gcc/java')
-rw-r--r--gcc/java/ChangeLog5
-rw-r--r--gcc/java/parse.c7
-rw-r--r--gcc/java/parse.y7
3 files changed, 9 insertions, 10 deletions
diff --git a/gcc/java/ChangeLog b/gcc/java/ChangeLog
index 8bbdad3..96a81ce 100644
--- a/gcc/java/ChangeLog
+++ b/gcc/java/ChangeLog
@@ -1,3 +1,8 @@
+Thu Oct 21 01:27:31 1999 Alexandre Petit-Bianco <apbianco@cygnus.com>
+
+ * parse.y (resolve_qualified_expression_name): Handle MODIFY_EXPR.
+ (qualify_ambiguous_name): Likewise.
+
Wed Oct 20 01:41:47 1999 Alexandre Petit-Bianco <apbianco@cygnus.com>
* parse.y (java_complete_tree): fold_constant_for_init to work on
diff --git a/gcc/java/parse.c b/gcc/java/parse.c
index 863d1ec..21520356 100644
--- a/gcc/java/parse.c
+++ b/gcc/java/parse.c
@@ -9262,6 +9262,7 @@ resolve_qualified_expression_name (wfl, found_decl, where_found, type_found)
case CONDITIONAL_EXPR:
case STRING_CST:
+ case MODIFY_EXPR:
*where_found = decl = java_complete_tree (qual_wfl);
if (decl == error_mark_node)
return 1;
@@ -10445,11 +10446,7 @@ qualify_ambiguous_name (id)
&& TREE_CODE (TREE_TYPE (qual_wfl)) == EXPR_WITH_FILE_LOCATION)
name = EXPR_WFL_NODE (TREE_TYPE (qual_wfl));
- else if (code == ARRAY_REF &&
- TREE_CODE (TREE_OPERAND (qual_wfl, 0)) == EXPR_WITH_FILE_LOCATION)
- name = EXPR_WFL_NODE (TREE_OPERAND (qual_wfl, 0));
-
- else if (code == CALL_EXPR &&
+ else if ((code == ARRAY_REF || code == CALL_EXPR || code == MODIFY_EXPR) &&
TREE_CODE (TREE_OPERAND (qual_wfl, 0)) == EXPR_WITH_FILE_LOCATION)
name = EXPR_WFL_NODE (TREE_OPERAND (qual_wfl, 0));
diff --git a/gcc/java/parse.y b/gcc/java/parse.y
index 1fabf80..76b91f2 100644
--- a/gcc/java/parse.y
+++ b/gcc/java/parse.y
@@ -6675,6 +6675,7 @@ resolve_qualified_expression_name (wfl, found_decl, where_found, type_found)
case CONDITIONAL_EXPR:
case STRING_CST:
+ case MODIFY_EXPR:
*where_found = decl = java_complete_tree (qual_wfl);
if (decl == error_mark_node)
return 1;
@@ -7858,11 +7859,7 @@ qualify_ambiguous_name (id)
&& TREE_CODE (TREE_TYPE (qual_wfl)) == EXPR_WITH_FILE_LOCATION)
name = EXPR_WFL_NODE (TREE_TYPE (qual_wfl));
- else if (code == ARRAY_REF &&
- TREE_CODE (TREE_OPERAND (qual_wfl, 0)) == EXPR_WITH_FILE_LOCATION)
- name = EXPR_WFL_NODE (TREE_OPERAND (qual_wfl, 0));
-
- else if (code == CALL_EXPR &&
+ else if ((code == ARRAY_REF || code == CALL_EXPR || code == MODIFY_EXPR) &&
TREE_CODE (TREE_OPERAND (qual_wfl, 0)) == EXPR_WITH_FILE_LOCATION)
name = EXPR_WFL_NODE (TREE_OPERAND (qual_wfl, 0));