RFR: 8336934: Clean up JavaLangReflectAccess [v2]

Chen Liang liach at openjdk.org
Thu Jul 25 22:33:44 UTC 2024


> Removed redundant APIs in `JavaLangReflectAccess` and added general warning against using `SharedSecrets`.
> 
> The cleanup in `JavaLangReflectAccess` is:
> - Converted `newConstructor` taking parameters to taking another constructor and a new accessor. The old existing API essentially does a copy and sets an accessor.
> - Removed lots of constructor getters, unused after `newConstructor` cleanup.
> - Removed accessor getter/setters, unused after `newConstructor` cleanup.
> - Removed `leafCopyMethod`. We can already use `getRoot` plus `copyMethod` to achieve the same effect.

Chen Liang has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains three additional commits since the last revision:

 - Remove editor folds, improve comments
 - Merge branch 'm5' into cleanup/reflect-access
 - 8336934: Clean up JavaLangReflectAccess

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/20290/files
  - new: https://git.openjdk.org/jdk/pull/20290/files/5d6c60bc..7973c8ff

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=20290&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=20290&range=00-01

  Stats: 8152 lines in 178 files changed: 5432 ins; 1729 del; 991 mod
  Patch: https://git.openjdk.org/jdk/pull/20290.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/20290/head:pull/20290

PR: https://git.openjdk.org/jdk/pull/20290


More information about the core-libs-dev mailing list