Re: Meeting today: IdentityClass

2021-05-06 Thread Dan Smith
> On May 5, 2021, at 8:39 AM, Remi Forax wrote: > > If it's possible, i would like to discuss about IdentityClass again. > > As noted in the last draft, adding IdentityClass automatically at runtime is > not a compatible change if tests that uses Class::getInterfaces() are not > written

Re: Meeting today: IdentityClass

2021-05-05 Thread forax
> De: "Brian Goetz" > À: "Remi Forax" , "valhalla-spec-experts" > > Envoyé: Mercredi 5 Mai 2021 20:20:07 > Objet: Re: Meeting today: IdentityClass > Here are some idioms I can imagine a use for with IdentityObject: > // parameter type &g

Re: Meeting today: IdentityClass

2021-05-05 Thread Brian Goetz
Here are some idioms I can imagine a use for with IdentityObject:     // parameter type     void withLock(IdentityObject monitor, Runnable task)     // type bound     Map map = ...  // gonna lock on keys     // dynamic check     if (x instanceof IdentityObject) {     sync (x) { task(); }   

Meeting today: IdentityClass

2021-05-05 Thread Remi Forax
If it's possible, i would like to discuss about IdentityClass again. As noted in the last draft, adding IdentityClass automatically at runtime is not a compatible change if tests that uses Class::getInterfaces() are not written correctly, and sadly, a lot of tests are written that way. I'm