Hi Christoph, fun little micro-optimization. :-)
My only nit is that I'd have preferred if you kept the indentation style, since the patch now shifts code around a bit (which makes it harder to review and see the history) /Claes On 2020-04-02 17:01, Langer, Christoph wrote:
Hi, please review a small improvement for the jlink VersionPropsPlugin. The Plugin modifies the bytecode of java/lang/VersionProps.class to replace the initializion of certain vendor specific system properties with custom values. This modification currently adds two bytecodes per constant, a pop and another ldc. I overhauled it to simply replace the original ldc of the old value with another ldc, loading the custom value. I was playing a bit with the plugin and tried to familiarize with the code – so that’s the outcome 😉 I also added an @SuppressWarnings("unused") in VersionProps.java.template to quiesce an IDE warning. Bug: https://bugs.openjdk.java.net/browse/JDK-8242039 Webrev: http://cr.openjdk.java.net/~clanger/webrevs/8242039.0/ Thanks Christoph