[kaffe] CVS kaffe (guilhem): Final fix (hopefully) for instanceof_interface.

Kaffe CVS cvs-commits at kaffe.org
Mon Dec 27 09:31:16 PST 2004


PatchSet 5726 
Date: 2004/12/27 17:26:56
Author: guilhem
Branch: HEAD
Tag: (none) 
Log:
Final fix (hopefully) for instanceof_interface.

        * kaffe/kaffevm/soft.c
        (instanceof_interface): Fixed instanceof implementation. It should
        work as expected now (tested against Ant). CSTATE_PREPARED is
        sufficient for implementors.

Members: 
	ChangeLog:1.3270->1.3271 
	WHATSNEW:1.35->1.36 
	kaffe/kaffevm/soft.c:1.74->1.75 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.3270 kaffe/ChangeLog:1.3271
--- kaffe/ChangeLog:1.3270	Mon Dec 27 16:09:42 2004
+++ kaffe/ChangeLog	Mon Dec 27 17:26:56 2004
@@ -1,5 +1,12 @@
 2004-12-27  Guilhem Lavaux  <guilhem at kaffe.org>
 
+	* kaffe/kaffevm/soft.c
+	(instanceof_interface): Fixed instanceof implementation. It should
+	work as expected now (tested against Ant). CSTATE_PREPARED is
+	sufficient for implementors.
+
+2004-12-27  Guilhem Lavaux  <guilhem at kaffe.org>
+
 	* config/alpha/jit-alpha.def,
 	config/i386/jit-i386.def,
 	config/i386/jit3-i386.def,
Index: kaffe/WHATSNEW
diff -u kaffe/WHATSNEW:1.35 kaffe/WHATSNEW:1.36
--- kaffe/WHATSNEW:1.35	Fri Jul 23 13:45:15 2004
+++ kaffe/WHATSNEW	Mon Dec 27 17:26:58 2004
@@ -21,6 +21,8 @@
 * Jessie merged in.
 * JZLib merged in.
 * GNU Classpath's implementation of Swing has been merged.
+* Tested in Ch environment.
+* Implemented weak references in the VM.
 
 What's New in Kaffe 1.1.3
 ------------------------------------------------------
Index: kaffe/kaffe/kaffevm/soft.c
diff -u kaffe/kaffe/kaffevm/soft.c:1.74 kaffe/kaffe/kaffevm/soft.c:1.75
--- kaffe/kaffe/kaffevm/soft.c:1.74	Sat Dec 25 19:09:13 2004
+++ kaffe/kaffe/kaffevm/soft.c	Mon Dec 27 17:27:00 2004
@@ -301,7 +301,7 @@
 	int i;
 	Hjava_lang_Class **impl_clazz;
 
-	if (oc->state < CSTATE_USABLE || c->state < CSTATE_USABLE || CLASS_IS_ARRAY(oc) || CLASS_IS_INTERFACE(oc))
+	if (oc->state < CSTATE_PREPARED || c->state < CSTATE_PREPARED || CLASS_IS_ARRAY(oc) || CLASS_IS_INTERFACE(oc))
 	  {
 	    /* Check 'total' interface list. If the class is not
 	     * prepared the dumb way is the only way. Arrays and interface do not have
@@ -321,7 +321,7 @@
 	    /* No interface implemented or this class is not implementing this
 	     * interface. Bailing out. */
 	    if (i == 0 || c->implementors == NULL ||
-		i >= (uintp)c->implementors[0] ||
+		i > (uintp)c->implementors[0] ||
 		c->implementors[i] == NULL)
 	      return 0;
 	    




More information about the kaffe mailing list