slawekjaranowski commented on code in PR #275:
URL: 
https://github.com/apache/maven-compiler-plugin/pull/275#discussion_r1943194797


##########
src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java:
##########
@@ -1889,7 +1889,9 @@ final String getImplicit() {
      * @see <a 
href="https://bugs.openjdk.org/browse/JDK-8318913";>JDK-8318913</a>
      */
     private void patchJdkModuleVersion(CompilerResult compilerResult, 
Set<File> sources) throws MojoExecutionException {
-        if (compilerResult.isSuccess() && 
getModuleDeclaration(sources).isPresent()) {
+        if (compilerResult.isSuccess()
+                && getModuleDeclaration(sources).isPresent()
+                && !JavaVersion.JAVA_VERSION.isAtLeast("22")) {

Review Comment:
   Will not detect JDK version used by toolchains, 
   we can use different JDK for compiling than executing project build.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to