以下可以正常編譯: Object o = new Object(); System.out.println(o instanceof Cloneable);但這不是: String s = new String(); System.out.println(s instanceof Cloneable);引發(fā)編譯器錯(cuò)誤。問(wèn)題是什么?
instanceof-不兼容的條件操作數(shù)類(lèi)型
達(dá)令說(shuō)
2019-09-24 15:36:47