*
* int -> int
* int[] -> [I
- * String -> java.lang.String
- * String[] -> [Ljava.lang.String;
- * String[][] -> [[Ljava.lang.String;
+ * String -> java/lang/String
+ * String[] -> [Ljava/lang/String;
+ * String[][] -> [[Ljava/lang/String;
*
* <2do> this is really not very efficient
*/
public static boolean instanceOf (String type, String ofType) {
int bType = getBuiltinTypeFromSignature(type);
- if ((bType == T_ARRAY) && ofType.equals("Ljava.lang.Object;")) {
+ if ((bType == T_ARRAY) && ofType.equals("Ljava/lang/Object;")) {
return true;
}
assertNull(c.getResource("not_existing_resources"));
}
}
+
+ @Test
+ public void instanceOfArrayTest() {
+ String[] args = new String[0];
+ if (verifyNoPropertyViolation()) {
+ assert args instanceof Object;
+ }
+ }
}