This is an automated email from the ASF dual-hosted git repository. paulk pushed a commit to branch GROOVY_5_0_X in repository https://gitbox.apache.org/repos/asf/groovy.git
commit 66470b0840299813a1fe80d655196659cbc69af2 Author: Paul King <[email protected]> AuthorDate: Tue Oct 7 13:04:12 2025 +1000 GROOVY-11771: Bump asm to 9.9 and add JDK26 constants --- src/main/java/org/codehaus/groovy/control/CompilerConfiguration.java | 5 ++++- .../org/codehaus/groovy/control/CompilerConfigurationTest.java | 4 ++-- versions.properties | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/main/java/org/codehaus/groovy/control/CompilerConfiguration.java b/src/main/java/org/codehaus/groovy/control/CompilerConfiguration.java index 07b0761076..a468af9046 100644 --- a/src/main/java/org/codehaus/groovy/control/CompilerConfiguration.java +++ b/src/main/java/org/codehaus/groovy/control/CompilerConfiguration.java @@ -110,6 +110,8 @@ public class CompilerConfiguration { public static final String JDK24 = "24"; /** This (<code>"25"</code>) is the value for targetBytecode to compile for a JDK 25. */ public static final String JDK25 = "25"; + /** This (<code>"26"</code>) is the value for targetBytecode to compile for a JDK 26. */ + public static final String JDK26 = "26"; /** * JDK version to bytecode version mapping. @@ -129,7 +131,8 @@ public class CompilerConfiguration { JDK22, Opcodes.V22, JDK23, Opcodes.V23, JDK24, Opcodes.V24, - JDK25, Opcodes.V25 + JDK25, Opcodes.V25, + JDK26, Opcodes.V26 ); public static final String DEFAULT_TARGET_BYTECODE = defaultTargetBytecode(); diff --git a/src/test/groovy/org/codehaus/groovy/control/CompilerConfigurationTest.java b/src/test/groovy/org/codehaus/groovy/control/CompilerConfigurationTest.java index 5eb2a117a8..4d3c54d0e1 100644 --- a/src/test/groovy/org/codehaus/groovy/control/CompilerConfigurationTest.java +++ b/src/test/groovy/org/codehaus/groovy/control/CompilerConfigurationTest.java @@ -297,8 +297,8 @@ public final class CompilerConfigurationTest { @Test // GROOVY-10278 public void testTargetVersion() { CompilerConfiguration config = new CompilerConfiguration(); - String[] inputs = {"1.3", "1.4", "1.5", "1.6", "1.7", "1.8", "1.9", "5" , "6" , "7" , "8" , "9" , "9.0", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26"}; - String[] expect = {"11" , "11" , "11" , "11" , "11" , "11" , "11" , "11", "11", "11", "11", "11", "11" , "11", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "25"}; + String[] inputs = {"1.3", "1.4", "1.5", "1.6", "1.7", "1.8", "1.9", "5" , "6" , "7" , "8" , "9" , "9.0", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27"}; + String[] expect = {"11" , "11" , "11" , "11" , "11" , "11" , "11" , "11", "11", "11", "11", "11", "11" , "11", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "26"}; assertArrayEquals(expect, Arrays.stream(inputs).map(v -> { config.setTargetBytecode(v); return config.getTargetBytecode(); }).toArray(String[]::new)); } } diff --git a/versions.properties b/versions.properties index 7555464425..cd945ad1be 100644 --- a/versions.properties +++ b/versions.properties @@ -20,7 +20,7 @@ asciidoctorDiagram=2.2.17 asciidoctorGroovyDsl=2.0.2 asciidoctorPdf=2.3.19 asciidoctorj=2.5.11 -asm=9.8 +asm=9.9 bridger=1.6.Final checkstyle=10.26.1 cobertura=1.9.4.1
