diff options
author | Alexandre Petit-Bianco <apbianco@gcc.gnu.org> | 2001-02-16 14:31:52 -0800 |
---|---|---|
committer | Alexandre Petit-Bianco <apbianco@gcc.gnu.org> | 2001-02-16 14:31:52 -0800 |
commit | 055adbaa1e397cd584fedb5cbe1a71651a7a0232 (patch) | |
tree | e0047553957bce79ad10a84c5610e93daba3c3aa /gcc/java/expr.c | |
parent | 2c1be3223f5bbc9e2238d15e8a48d37b1f02fdbe (diff) | |
download | gcc-055adbaa1e397cd584fedb5cbe1a71651a7a0232.zip gcc-055adbaa1e397cd584fedb5cbe1a71651a7a0232.tar.gz gcc-055adbaa1e397cd584fedb5cbe1a71651a7a0232.tar.bz2 |
expr.c (build_instanceof): Check for arrays when trying fold to false.
2001-02-15 Alexandre Petit-Bianco <apbianco@redhat.com>
* expr.c (build_instanceof): Check for arrays when trying fold to
false.
(http://gcc.gnu.org/ml/gcc-patches/2001-02/msg00993.html)
From-SVN: r39778
Diffstat (limited to 'gcc/java/expr.c')
-rw-r--r-- | gcc/java/expr.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/java/expr.c b/gcc/java/expr.c index 70a2fe9..4f7c0dc 100644 --- a/gcc/java/expr.c +++ b/gcc/java/expr.c @@ -1157,7 +1157,9 @@ build_instanceof (value, type) value, boolean_true_node, boolean_false_node); } - else if (DECL_P (klass) && DECL_P (valclass) + else if (! TYPE_ARRAY_P (type) + && ! TYPE_ARRAY_P (valtype) + && DECL_P (klass) && DECL_P (valclass) && ! CLASS_INTERFACE (valclass) && ! CLASS_INTERFACE (klass) && ! inherits_from_p (type, valtype) |