On Fri, 17 Sep 2021 17:10:10 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:
>> "different set implementation" as part of the spec may challenge the >> compatibility test developers to prove or disprove that statement. >> The type of an instance is frequently understood to be the "implementation". >> The visible type returned from Properties.entrySet() is SynchronizedSet. >> Anyone can create one of those. >> That statement might mislead a subclass into thinking they can not/must not >> return a SynchronizedSet if they want the built-in sorting. >> I'm thinking that wording it in other term of the subclass might be better: >> "...sort order of the keys in the entrySet() unless entrySet() is overridden >> by a subclass to return a different value than 'super.entrySet'(). " >> The existing implementation is fine. > > I agree that this is a better formulation than what I suggested :-) Done. I've updated the PR to use Roger's suggested text and yes it's much more precise than what we had so far. ------------- PR: https://git.openjdk.java.net/jdk/pull/5372