RFR: 8316970: Add internal annotation to mark restricted methods [v2]

Maurizio Cimadamore mcimadamore at openjdk.org
Wed Sep 27 17:29:29 UTC 2023


> This patch adds a new internal annotation that is used to mark all restricted me
> thods in the FFM API. The new annotation is similar to the one we used for preview API methods.
> 
> We plan to use the new annotation for adding new javac warnings when calling restricted methods, as well as to add better javadoc support for restricted methods.
> 
> I have added a test which, similar to the test for `@CallerSensitive` checks all methods in `java.base` that are annotated with `@Restricted` and makes sure they conform to the list of restricted methods.

Maurizio Cimadamore has updated the pull request incrementally with one additional commit since the last revision:

  Drop requires tag from test

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/15947/files
  - new: https://git.openjdk.org/jdk/pull/15947/files/f2f3692a..775d0887

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

  Stats: 1 line in 1 file changed: 0 ins; 1 del; 0 mod
  Patch: https://git.openjdk.org/jdk/pull/15947.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/15947/head:pull/15947

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


More information about the core-libs-dev mailing list