dragome-sdk icon indicating copy to clipboard operation
dragome-sdk copied to clipboard

Compare Object.class bug

Open xpenatan opened this issue 7 years ago • 0 comments

There a bug in comparing class. (Object.class)

		Class nextClass = type;
		while (nextClass != Object.class) {
			classHierarchy.add(nextClass);
			nextClass = nextClass.getSuperclass();
			System.out.println("nextClass: " + nextClass);
		}

Output: type: class com.badlogic.gdx.math.Vector3 helpers.js:148 nextClass: class java.lang.Object helpers.js:148 nextClass: null

image

com.badlogic.gdx.math.Vector3 have been created using libgdx Json class which its by reflection.

Printing each super class you can see that it prints "java.lang.Object" but the compare with Object.class failed.

xpenatan avatar May 29 '17 03:05 xpenatan