Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
On Wed, 15 Mar 2023 21:00:24 GMT, Pavel Rappo wrote: >> True, my previous suggestion is largely trivial. >> >> In addition, I suggest to run `replaceAll` to ensure the map elements of >> each value of `namedMembers` is unmodifiable as well: >> >> namedMembers.replaceAll((k, m) -> { >> m.re

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v4]

2023-03-15 Thread Pavel Rappo
> Please review a change to clean up and simplify LocalMemberTable; a container > to cache, classify, and provide efficient lookup for the return value of > `TypeElement.getEnclosedElements()`. > > While the change primarily targets internals of LocalMemberTable, it also > affects its clients:

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
On Wed, 15 Mar 2023 18:56:11 GMT, Chen Liang wrote: >> TANSTAAFL >> >> I suggest to leave the code as-is. > > True, my previous suggestion is largely trivial. > > In addition, I suggest to run `replaceAll` to ensure the map elements of each > value of `namedMembers` is unmodifiable as well: >

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
On Wed, 15 Mar 2023 20:18:11 GMT, Jonathan Gibbons wrote: >> I believe that shallow unmodifiability of namedMembers is a bug, which you >> spotted. We should either fix it by making it deeply unmodifiable, or remove >> this defensiveness altogether: those lists and maps (especially maps) are >

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v3]

2023-03-15 Thread Pavel Rappo
> Please review a change to clean up and simplify LocalMemberTable; a container > to cache, classify, and provide efficient lookup for the return value of > `TypeElement.getEnclosedElements()`. > > While the change primarily targets internals of LocalMemberTable, it also > affects its clients:

Re: RFR: 8301991: Convert l10n properties resource bundles to UTF-8 native

2023-03-15 Thread Naoto Sato
On Thu, 23 Feb 2023 09:04:23 GMT, Justin Lu wrote: > This PR converts Unicode sequences to UTF-8 native in .properties file. > (Excluding the Unicode space and tab sequence). The conversion was done using > native2ascii. > > In addition, the build logic is adjusted to support reading in the >

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Jonathan Gibbons
On Wed, 15 Mar 2023 20:01:31 GMT, Pavel Rappo wrote: >> True, my previous suggestion is largely trivial. >> >> In addition, I suggest to run `replaceAll` to ensure the map elements of >> each value of `namedMembers` is unmodifiable as well: >> >> namedMembers.replaceAll((k, m) -> { >> m.re

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
On Wed, 15 Mar 2023 18:56:11 GMT, Chen Liang wrote: >> TANSTAAFL >> >> I suggest to leave the code as-is. > > True, my previous suggestion is largely trivial. > > In addition, I suggest to run `replaceAll` to ensure the map elements of each > value of `namedMembers` is unmodifiable as well: >

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Chen Liang
On Wed, 15 Mar 2023 18:54:02 GMT, Jonathan Gibbons wrote: >> I don't mind either way; @jonathan-gibbons do you have a preference? > > TANSTAAFL > > I suggest to leave the code as-is. True, my previous suggestion is largely trivial. In addition, I suggest to run `replaceAll` to ensure the map e

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Jonathan Gibbons
On Wed, 15 Mar 2023 18:48:02 GMT, Pavel Rappo wrote: >> There's a cost of changing that to this: >> >> // protect from unintended change >> orderedMembers.replaceAll((k, l) -> Collections.unmodifiableList(l)); >> namedMembers.replaceAll((k, m) -> Collections.unmodifiableMap(m)); >>

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
On Wed, 15 Mar 2023 18:46:17 GMT, Pavel Rappo wrote: >> src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/toolkit/util/VisibleMemberTable.java >> line 888: >> >>> 886: for (Kind kind : Kind.values()) { >>> 887: orderedMembers.compute(kind, (k, v) -> v == nul

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
On Wed, 15 Mar 2023 18:20:10 GMT, Chen Liang wrote: >> Pavel Rappo has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Trivially rephrase TODO >> - Address feedback >> >> - renames simplename to simpleName >> - links to the re

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
On Wed, 15 Mar 2023 17:52:29 GMT, Jonathan Gibbons wrote: >> Pavel Rappo has updated the pull request incrementally with two additional >> commits since the last revision: >> >> - Trivially rephrase TODO >> - Address feedback >> >> - renames simplename to simpleName >> - links to

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Chen Liang
On Wed, 15 Mar 2023 18:12:57 GMT, Pavel Rappo wrote: >> Please review a change to clean up and simplify LocalMemberTable; a >> container to cache, classify, and provide efficient lookup for the return >> value of `TypeElement.getEnclosedElements()`. >> >> While the change primarily targets int

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Jonathan Gibbons
On Wed, 15 Mar 2023 18:12:57 GMT, Pavel Rappo wrote: >> Please review a change to clean up and simplify LocalMemberTable; a >> container to cache, classify, and provide efficient lookup for the return >> value of `TypeElement.getEnclosedElements()`. >> >> While the change primarily targets int

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Pavel Rappo
> Please review a change to clean up and simplify LocalMemberTable; a container > to cache, classify, and provide efficient lookup for the return value of > `TypeElement.getEnclosedElements()`. > > While the change primarily targets internals of LocalMemberTable, it also > affects its clients:

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable) [v2]

2023-03-15 Thread Jonathan Gibbons
On Wed, 15 Mar 2023 18:08:04 GMT, Pavel Rappo wrote: >> Please review a change to clean up and simplify LocalMemberTable; a >> container to cache, classify, and provide efficient lookup for the return >> value of `TypeElement.getEnclosedElements()`. >> >> While the change primarily targets int

Re: RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable)

2023-03-15 Thread Jonathan Gibbons
On Wed, 15 Mar 2023 15:48:37 GMT, Pavel Rappo wrote: > Please review a change to clean up and simplify LocalMemberTable; a container > to cache, classify, and provide efficient lookup for the return value of > `TypeElement.getEnclosedElements()`. > > While the change primarily targets internal

Re: RFR: 8301991: Convert l10n properties resource bundles to UTF-8 native

2023-03-15 Thread Archie L . Cobbs
On Thu, 23 Feb 2023 09:04:23 GMT, Justin Lu wrote: > This PR converts Unicode sequences to UTF-8 native in .properties file. > (Excluding the Unicode space and tab sequence). The conversion was done using > native2ascii. > > In addition, the build logic is adjusted to support reading in the >

Re: RFR: 8301991: Convert l10n properties resource bundles to UTF-8 native

2023-03-15 Thread Jonathan Gibbons
On Thu, 23 Feb 2023 09:04:23 GMT, Justin Lu wrote: > This PR converts Unicode sequences to UTF-8 native in .properties file. > (Excluding the Unicode space and tab sequence). The conversion was done using > native2ascii. > > In addition, the build logic is adjusted to support reading in the >

Re: RFR: 8301991: Convert l10n properties resource bundles to UTF-8 native

2023-03-15 Thread Justin Lu
On Tue, 7 Mar 2023 23:15:14 GMT, Jonathan Gibbons wrote: >> This PR converts Unicode sequences to UTF-8 native in .properties file. >> (Excluding the Unicode space and tab sequence). The conversion was done >> using native2ascii. >> >> In addition, the build logic is adjusted to support readin

RFR: 8301991: Convert l10n properties resource bundles to UTF-8 native

2023-03-15 Thread Justin Lu
This PR converts Unicode sequences to UTF-8 native in .properties file. (Excluding the Unicode space and tab sequence). The conversion was done using native2ascii. In addition, the build logic is adjusted to support reading in the .properties files as UTF-8 during the conversion from .propertie

RFR: 8304146: Refactor VisibleMemberTable (LocalMemberTable)

2023-03-15 Thread Pavel Rappo
Please review a change to clean up and simplify LocalMemberTable; a container to cache, classify, and provide efficient lookup for the return value of `TypeElement.getEnclosedElements()`. While the change primarily targets internals of LocalMemberTable, it also affects its clients: in particula