void () { doTest("java.lang.ClassCastException: class XYZ cannot be cast to class java.lang.Number", "Find why 'obj' could be not instanceof java.lang.Number (not-null)", "class X {static void test(Object obj) {System.out.println(((Number) obj).intValue());}}"); }