RFR: 8305083: Remove finalize() from test/hotspot/jtreg/vmTestbase/nsk/share/ and /jpda that are used in serviceability/dcmd/framework tests [v2]

David Holmes dholmes at openjdk.org
Fri May 5 13:01:19 UTC 2023


On Sat, 29 Apr 2023 15:54:23 GMT, Afshin Zafari <duke at openjdk.org> wrote:

>> The `finalize()` method is removed from base classes/interfaces and are replaced by a Cleaner callback..
>
> Afshin Zafari has updated the pull request incrementally with one additional commit since the last revision:
> 
>   8305083: Remove finalize() from test/hotspot/jtreg/vmTestbase/nsk/share/ and /jpda that are used in serviceability/dcmd/framework tests

> Default methods for interface classes were invented to solve a problem of compatibility if I remember correctly. 

Yes they were added a way to extend existing interfaces, but the point is that a default method provides an implementation that will work "good enough" for any implementing class in general - and is this case the default implementation is all that is needed (it is like adding a method to a common base class).

-------------

PR Comment: https://git.openjdk.org/jdk/pull/13420#issuecomment-1536224855


More information about the hotspot-runtime-dev mailing list