On Tue, 30 Aug 2022 18:13:21 GMT, Ioi Lam <ik...@openjdk.org> wrote: >> compute_hash() is always called on a live WeakHandle so will never return >> null. > > I think you should add an assert that the `protection_domain.resolve()` never > returns null, with a comment explaining why.
I agree. In general if code is using WeakHandle's then I would expect to see null checks. ------------- PR: https://git.openjdk.org/jdk/pull/10043