Right, so returns false for JDK <9 and true for JDK >= 9. That's more than confusing, and a bit of a problem. It is "funny" that the docs says "returns empty string if it's an anonymous class", and that now it is "if it returns empty string, then it's an anonymous class". The logic is pretty reversed...
2015-06-15 6:25 GMT+02:00 Jochen Theodorou <[email protected]>: > Am 14.06.2015 16:54, schrieb Cédric Champeau: > [...] > >> I don't feel it is as easy as fixing a test. First of all, our closure >> generated classes are *not* anonymous. ClosureWriter doesn't generate >> anonymous classes, and we can verify it easily: >> >> def cl = { -> '' } >> assert cl.class.anonymousClass == false >> > > just tested again, and I get true. It has to be true, because > isAnonymousClass() is now defined by getSimpleName().equals("") > > > bye blackdrag > > -- > Jochen "blackdrag" Theodorou > blog: http://blackdragsview.blogspot.com/ > >
