[code-reflection] RFR: Turn compiler plugin into simple SPI
Maurizio Cimadamore
mcimadamore at openjdk.org
Mon Nov 18 14:24:28 UTC 2024
This PR is a small followup to the changes to turn compiler code reflection support into a compiler plugin.
Turns out that the new plugin required several hacks and workaround, to make sure that the plugin would only run when strictly required (not to affect outcome of compilation if the plugin was disabled). We can get rid of all such workarounds by turning the plugin into a plain and simple SPI. There is a new `ReflectMethodsProxy` interface, which is implemented by the new module (see `ReflectMethods.Provider`). This allows javac to more or less call into the new pipeline step as it did before the incubating change, which leads to code that is much simpler to maintain.
-------------
Commit messages:
- Initial push
Changes: https://git.openjdk.org/babylon/pull/275/files
Webrev: https://webrevs.openjdk.org/?repo=babylon&pr=275&range=00
Stats: 289 lines in 8 files changed: 103 ins; 181 del; 5 mod
Patch: https://git.openjdk.org/babylon/pull/275.diff
Fetch: git fetch https://git.openjdk.org/babylon.git pull/275/head:pull/275
PR: https://git.openjdk.org/babylon/pull/275
More information about the babylon-dev
mailing list