re PR java/20056 ('verification failed: incompatible type on stack' with --indirect...
authorTom Tromey <tromey@redhat.com>
Sat, 19 Feb 2005 04:02:09 +0000 (04:02 +0000)
committerTom Tromey <tromey@gcc.gnu.org>
Sat, 19 Feb 2005 04:02:09 +0000 (04:02 +0000)
PR java/20056:
* verify-impl.c (types_equal): Fixed test.

From-SVN: r95267

gcc/java/ChangeLog
gcc/java/verify-impl.c

index 84a0e78af1cd55f270b166c40247eefa4efbbfc8..c1d48086be97c0f940cdea3ad5e7776ea696624e 100644 (file)
@@ -1,5 +1,8 @@
 2005-02-18  Tom Tromey  <tromey@redhat.com>
 
+       PR java/20056:
+       * verify-impl.c (types_equal): Fixed test.
+
        PR java/20056:
        * verify-glue.c (vfy_class_has_field): New function.
        * verify.h (vfy_class_has_field): Declare.
index 376f74948603af282817333fbc44633188ba3608..bd681d2bce06ac1e4bef8f0b8e868819e3792b2f 100644 (file)
@@ -743,8 +743,9 @@ types_compatible (type *t, type *k)
 static bool
 types_equal (type *t1, type *t2)
 {
-  if (t1->key != reference_type || t1->key != uninitialized_reference_type
-      || t2->key != reference_type || t2->key != uninitialized_reference_type)
+  if ((t1->key != reference_type && t1->key != uninitialized_reference_type)
+      || (t2->key != reference_type
+         && t2->key != uninitialized_reference_type))
     return false;
   /* Only single-ref types are allowed.  */
   if (t1->klass->ref_next || t2->klass->ref_next)