You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2020/10/26 19:45:56 UTC

[tomcat] branch master updated (c4787f4 -> cc0dfd4)

This is an automated email from the ASF dual-hosted git repository.

markt pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git.


    from c4787f4  Code cleanup
     new 7b51c5d  Add support for specifying Java 16 with the JDT compiler
     new 517f668  Update JDT to 4.17 / 3.23.0 (same JAR - different numbering schemes)
     new a481122  Use constants for Java 13 and Java 14 that are now available
     new cc0dfd4  Make formatting consistent

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 build.properties.default                           |  12 +-
 java/org/apache/jasper/compiler/JDTCompiler.java   | 147 ++++++++-------------
 res/ide-support/eclipse/eclipse.classpath          |   2 +-
 res/ide-support/idea/tomcat.iml                    |   2 +-
 .../netbeans/nb-tomcat-build.properties            |   2 +-
 res/ide-support/netbeans/project.xml               |   2 +-
 res/maven/tomcat-jasper.pom                        |   2 +-
 webapps/docs/changelog.xml                         |   9 ++
 8 files changed, 74 insertions(+), 104 deletions(-)


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[tomcat] 04/04: Make formatting consistent

Posted by ma...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git

commit cc0dfd42bc61bee15cc0d7179f271889ad7bf324
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Oct 26 19:33:24 2020 +0000

    Make formatting consistent
---
 java/org/apache/jasper/compiler/JDTCompiler.java | 114 ++++++++---------------
 1 file changed, 38 insertions(+), 76 deletions(-)

diff --git a/java/org/apache/jasper/compiler/JDTCompiler.java b/java/org/apache/jasper/compiler/JDTCompiler.java
index 3377112..4722a4a 100644
--- a/java/org/apache/jasper/compiler/JDTCompiler.java
+++ b/java/org/apache/jasper/compiler/JDTCompiler.java
@@ -279,43 +279,31 @@ public class JDTCompiler extends org.apache.jasper.compiler.Compiler {
         if(ctxt.getOptions().getCompilerSourceVM() != null) {
             String opt = ctxt.getOptions().getCompilerSourceVM();
             if(opt.equals("1.1")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_1);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_1);
             } else if(opt.equals("1.2")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_2);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_2);
             } else if(opt.equals("1.3")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_3);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_3);
             } else if(opt.equals("1.4")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_4);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_4);
             } else if(opt.equals("1.5")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_5);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_5);
             } else if(opt.equals("1.6")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_6);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_6);
             } else if(opt.equals("1.7")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_7);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_7);
             } else if(opt.equals("1.8")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_1_8);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_8);
             // Version format changed from Java 9 onwards.
             // Support old format that was used in EA implementation as well
             } else if(opt.equals("9") || opt.equals("1.9")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_9);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_9);
             } else if(opt.equals("10")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_10);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_10);
             } else if(opt.equals("11")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_11);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_11);
             } else if(opt.equals("12")) {
-                settings.put(CompilerOptions.OPTION_Source,
-                             CompilerOptions.VERSION_12);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_12);
             } else if(opt.equals("13")) {
                 settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_13);
             } else if(opt.equals("14")) {
@@ -332,72 +320,50 @@ public class JDTCompiler extends org.apache.jasper.compiler.Compiler {
                 settings.put(CompilerOptions.OPTION_Source, "16");
             } else {
                 log.warn(Localizer.getMessage("jsp.warning.unknown.sourceVM", opt));
-                settings.put(CompilerOptions.OPTION_Source,
-                        CompilerOptions.VERSION_1_8);
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_8);
             }
         } else {
             // Default to 1.8
-            settings.put(CompilerOptions.OPTION_Source,
-                    CompilerOptions.VERSION_1_8);
+            settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_1_8);
         }
 
         // Target JVM
         if(ctxt.getOptions().getCompilerTargetVM() != null) {
             String opt = ctxt.getOptions().getCompilerTargetVM();
             if(opt.equals("1.1")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_1);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_1);
             } else if(opt.equals("1.2")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_2);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_2);
             } else if(opt.equals("1.3")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_3);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_3);
             } else if(opt.equals("1.4")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_4);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_4);
             } else if(opt.equals("1.5")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_5);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_1_5);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_5);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_1_5);
             } else if(opt.equals("1.6")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_6);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_1_6);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_6);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_1_6);
             } else if(opt.equals("1.7")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_7);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_1_7);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_7);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_1_7);
             } else if(opt.equals("1.8")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_1_8);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_1_8);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_8);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_1_8);
             // Version format changed from Java 9 onwards.
             // Support old format that was used in EA implementation as well
             } else if(opt.equals("9") || opt.equals("1.9")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                             CompilerOptions.VERSION_9);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_9);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_9);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_9);
             } else if(opt.equals("10")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                        CompilerOptions.VERSION_10);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_10);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_10);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_10);
             } else if(opt.equals("11")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                        CompilerOptions.VERSION_11);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_11);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_11);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_11);
             } else if(opt.equals("12")) {
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                        CompilerOptions.VERSION_12);
-                settings.put(CompilerOptions.OPTION_Compliance,
-                        CompilerOptions.VERSION_12);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_12);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_12);
             } else if(opt.equals("13")) {
                 settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_13);
                 settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_13);
@@ -418,19 +384,15 @@ public class JDTCompiler extends org.apache.jasper.compiler.Compiler {
                 settings.put(CompilerOptions.OPTION_Compliance, "16");
             } else {
                 log.warn(Localizer.getMessage("jsp.warning.unknown.targetVM", opt));
-                settings.put(CompilerOptions.OPTION_TargetPlatform,
-                        CompilerOptions.VERSION_1_8);
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_8);
             }
         } else {
             // Default to 1.8
-            settings.put(CompilerOptions.OPTION_TargetPlatform,
-                    CompilerOptions.VERSION_1_8);
-            settings.put(CompilerOptions.OPTION_Compliance,
-                    CompilerOptions.VERSION_1_8);
+            settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_1_8);
+            settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_1_8);
         }
 
-        final IProblemFactory problemFactory =
-            new DefaultProblemFactory(Locale.getDefault());
+        final IProblemFactory problemFactory = new DefaultProblemFactory(Locale.getDefault());
 
         final ICompilerRequestor requestor = new ICompilerRequestor() {
                 @Override


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[tomcat] 03/04: Use constants for Java 13 and Java 14 that are now available

Posted by ma...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git

commit a4811220f40e1e699f373da4e3dc2e1459a83cdc
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Oct 26 19:31:33 2020 +0000

    Use constants for Java 13 and Java 14 that are now available
---
 java/org/apache/jasper/compiler/JDTCompiler.java | 24 ++++++------------------
 1 file changed, 6 insertions(+), 18 deletions(-)

diff --git a/java/org/apache/jasper/compiler/JDTCompiler.java b/java/org/apache/jasper/compiler/JDTCompiler.java
index a5a5806..3377112 100644
--- a/java/org/apache/jasper/compiler/JDTCompiler.java
+++ b/java/org/apache/jasper/compiler/JDTCompiler.java
@@ -317,15 +317,9 @@ public class JDTCompiler extends org.apache.jasper.compiler.Compiler {
                 settings.put(CompilerOptions.OPTION_Source,
                              CompilerOptions.VERSION_12);
             } else if(opt.equals("13")) {
-                // Constant not available in latest ECJ version shipped with
-                // Tomcat. May be supported in a snapshot build.
-                // This is checked against the actual version below.
-                settings.put(CompilerOptions.OPTION_Source, "13");
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_13);
             } else if(opt.equals("14")) {
-                // Constant not available in latest ECJ version shipped with
-                // Tomcat. May be supported in a snapshot build.
-                // This is checked against the actual version below.
-                settings.put(CompilerOptions.OPTION_Source, "14");
+                settings.put(CompilerOptions.OPTION_Source, CompilerOptions.VERSION_14);
             } else if(opt.equals("15")) {
                 // Constant not available in latest ECJ version shipped with
                 // Tomcat. May be supported in a snapshot build.
@@ -405,17 +399,11 @@ public class JDTCompiler extends org.apache.jasper.compiler.Compiler {
                 settings.put(CompilerOptions.OPTION_Compliance,
                         CompilerOptions.VERSION_12);
             } else if(opt.equals("13")) {
-                // Constant not available in latest ECJ version shipped with
-                // Tomcat. May be supported in a snapshot build.
-                // This is checked against the actual version below.
-                settings.put(CompilerOptions.OPTION_TargetPlatform, "13");
-                settings.put(CompilerOptions.OPTION_Compliance, "13");
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_13);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_13);
             } else if(opt.equals("14")) {
-                // Constant not available in latest ECJ version shipped with
-                // Tomcat. May be supported in a snapshot build.
-                // This is checked against the actual version below.
-                settings.put(CompilerOptions.OPTION_TargetPlatform, "14");
-                settings.put(CompilerOptions.OPTION_Compliance, "14");
+                settings.put(CompilerOptions.OPTION_TargetPlatform, CompilerOptions.VERSION_14);
+                settings.put(CompilerOptions.OPTION_Compliance, CompilerOptions.VERSION_14);
             } else if(opt.equals("15")) {
                 // Constant not available in latest ECJ version shipped with
                 // Tomcat. May be supported in a snapshot build.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[tomcat] 02/04: Update JDT to 4.17 / 3.23.0 (same JAR - different numbering schemes)

Posted by ma...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git

commit 517f6689f6d9be236aa8234c3edf190030529f70
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Oct 26 19:29:50 2020 +0000

    Update JDT to 4.17 / 3.23.0 (same JAR - different numbering schemes)
---
 build.properties.default                            | 12 ++++++------
 res/ide-support/eclipse/eclipse.classpath           |  2 +-
 res/ide-support/idea/tomcat.iml                     |  2 +-
 res/ide-support/netbeans/nb-tomcat-build.properties |  2 +-
 res/ide-support/netbeans/project.xml                |  2 +-
 res/maven/tomcat-jasper.pom                         |  2 +-
 webapps/docs/changelog.xml                          |  3 +++
 7 files changed, 14 insertions(+), 11 deletions(-)

diff --git a/build.properties.default b/build.properties.default
index 3c296cf..1b45cd5 100644
--- a/build.properties.default
+++ b/build.properties.default
@@ -129,15 +129,15 @@ wsdl4j-lib.loc=${base-maven.loc}/wsdl4j/wsdl4j/${wsdl4j-lib.version}/wsdl4j-${ws
 # ----- Eclipse JDT, version 4.7 or later -----#
 # See https://cwiki.apache.org/confluence/display/TOMCAT/Managing+Tomcat%27s+Dependency+on+the+Eclipse+JDT+Core+Batch+Compiler
 #
-# Checksum is from "SHA512 Checksums for 4.15" link at
-# http://download.eclipse.org/eclipse/downloads/drops4/R-4.15-202003050155/
-# http://download.eclipse.org/eclipse/downloads/drops4/R-4.15-202003050155/checksum/eclipse-4.15-SUMSSHA512
+# Checksum is from "SHA512 Checksums for 4.17" link at
+# http://download.eclipse.org/eclipse/downloads/drops4/R-4.17-202009021800/
+# http://download.eclipse.org/eclipse/downloads/drops4/R-4.17-202009021800/checksum/eclipse-4.17-SUMSSHA512
 #
-jdt.version=4.15
-jdt.release=R-4.15-202003050155/
+jdt.version=4.17
+jdt.release=R-4.17-202009021800
 jdt.checksum.enabled=true
 jdt.checksum.algorithm=SHA-512
-jdt.checksum.value=41311832a593d13ea84eebea087baa3bab16df381c70bd4c0f425caeb69eac1b41be2af27e40735ae16c039df4861fa93c3cfc4c21f84bad1c5eb1cb0e7ad351
+jdt.checksum.value=5e63e06eccd76a61249c7c6bd97e5b77dc37335bfdf316d941b00a16bae4f152d4306bac4e45c8422976187b0d77fe30cf7e6f6d4425f7732a3cb0cfa954385b
 jdt.home=${base.path}/ecj-${jdt.version}
 jdt.jar=${jdt.home}/ecj-${jdt.version}.jar
 # The download will be moved to the archive area eventually. We are taking care of that in advance.
diff --git a/res/ide-support/eclipse/eclipse.classpath b/res/ide-support/eclipse/eclipse.classpath
index 73e459e..5b34ea5 100644
--- a/res/ide-support/eclipse/eclipse.classpath
+++ b/res/ide-support/eclipse/eclipse.classpath
@@ -24,7 +24,7 @@
     <classpathentry kind="var" path="ANT_HOME/lib/ant.jar"/>
     <classpathentry kind="var" path="TOMCAT_LIBS_BASE/jaxrpc-1.1-rc4/geronimo-spec-jaxrpc-1.1-rc4.jar"/>
     <classpathentry kind="var" path="TOMCAT_LIBS_BASE/wsdl4j-1.6.3/wsdl4j-1.6.3.jar"/>
-    <classpathentry kind="var" path="TOMCAT_LIBS_BASE/ecj-4.15/ecj-4.15.jar"/>
+    <classpathentry kind="var" path="TOMCAT_LIBS_BASE/ecj-4.17/ecj-4.17.jar"/>
     <classpathentry kind="var" path="TOMCAT_LIBS_BASE/easymock-4.2/easymock-4.2.jar"/>
     <classpathentry kind="var" path="TOMCAT_LIBS_BASE/hamcrest-2.2/hamcrest-2.2.jar"/>
     <classpathentry kind="var" path="TOMCAT_LIBS_BASE/cglib-3.3.0/cglib-nodep-3.3.0.jar"/>
diff --git a/res/ide-support/idea/tomcat.iml b/res/ide-support/idea/tomcat.iml
index 22834db..268961a 100644
--- a/res/ide-support/idea/tomcat.iml
+++ b/res/ide-support/idea/tomcat.iml
@@ -68,7 +68,7 @@
     <orderEntry type="module-library">
       <library>
         <CLASSES>
-          <root url="jar://$TOMCAT_BUILD_LIBS$/ecj-4.15/ecj-4.15.jar!/" />
+          <root url="jar://$TOMCAT_BUILD_LIBS$/ecj-4.17/ecj-4.17.jar!/" />
         </CLASSES>
         <JAVADOC />
         <SOURCES />
diff --git a/res/ide-support/netbeans/nb-tomcat-build.properties b/res/ide-support/netbeans/nb-tomcat-build.properties
index bc3ff92..3400b83 100644
--- a/res/ide-support/netbeans/nb-tomcat-build.properties
+++ b/res/ide-support/netbeans/nb-tomcat-build.properties
@@ -37,7 +37,7 @@ nb-test.io-method=org.apache.coyote.http11.Http11NioProtocol
 # it is not possible to retrieve the classpaths from the build to
 # use in the NetBeans targets, so they must be explicitly declared
 
-nb-test.classpath=${test.classes}:${tomcat.build}/webapps/examples/WEB-INF/classes:${base.path}/junit-4.13/junit-4.13.jar:${base.path}/easymock-4.2/easymock-4.2.jar:${base.path}/objenesis-3.1/objenesis-3.1.jar:${base.path}/cglib-3.3.0/cglib-nodep-3.3.0.jar:${base.path}/hamcrest-2.2/hamcrest-2.2.jar:${base.path}/ecj-4.15/ecj-4.15.jar:${tomcat.classes}
+nb-test.classpath=${test.classes}:${tomcat.build}/webapps/examples/WEB-INF/classes:${base.path}/junit-4.13/junit-4.13.jar:${base.path}/easymock-4.2/easymock-4.2.jar:${base.path}/objenesis-3.1/objenesis-3.1.jar:${base.path}/cglib-3.3.0/cglib-nodep-3.3.0.jar:${base.path}/hamcrest-2.2/hamcrest-2.2.jar:${base.path}/ecj-4.17/ecj-4.17.jar:${tomcat.classes}
 
 # Extra properties used by the Tomcat project additional NetBeans targets.
 
diff --git a/res/ide-support/netbeans/project.xml b/res/ide-support/netbeans/project.xml
index a78164c..0dd6468 100644
--- a/res/ide-support/netbeans/project.xml
+++ b/res/ide-support/netbeans/project.xml
@@ -178,7 +178,7 @@
             -->
             <compilation-unit>
                 <package-root>java</package-root>
-                <classpath mode="compile">${base.path}/jaxrpc-1.1-rc4/geronimo-spec-jaxrpc-1.1-rc4.jar:${base.path}/wsdl4j-1.6.3/wsdl4j-1.6.3.jar:${base.path}/ecj-4.15/ecj-4.15.jar:${base.path}/bnd-5.1.1/biz.aQute.bnd-5.1.1.jar:${ant.includes}/</classpath>
+                <classpath mode="compile">${base.path}/jaxrpc-1.1-rc4/geronimo-spec-jaxrpc-1.1-rc4.jar:${base.path}/wsdl4j-1.6.3/wsdl4j-1.6.3.jar:${base.path}/ecj-4.17/ecj-4.17.jar:${base.path}/bnd-5.1.1/biz.aQute.bnd-5.1.1.jar:${ant.includes}/</classpath>
                 <source-level>1.7</source-level>
             </compilation-unit>
             <compilation-unit>
diff --git a/res/maven/tomcat-jasper.pom b/res/maven/tomcat-jasper.pom
index 991e48d..aa95105 100644
--- a/res/maven/tomcat-jasper.pom
+++ b/res/maven/tomcat-jasper.pom
@@ -60,7 +60,7 @@
     <dependency>
       <groupId>org.eclipse.jdt</groupId>
       <artifactId>ecj</artifactId>
-      <version>3.21.0</version>
+      <version>3.23.0</version>
     </dependency>
     <dependency>
       <groupId>org.apache.tomcat</groupId>
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 510f851..6d09d75 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -127,6 +127,9 @@
         with an ECJ version that does not support these values, a warning will
         be logged and the latest supported version will used. (markt)
       </add>
+      <update>
+        Update to the Eclipse JDT compiler 4.17. (markt)
+      </update>
     </changelog>
   </subsection>
   <subsection name="Web applications">


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


[tomcat] 01/04: Add support for specifying Java 16 with the JDT compiler

Posted by ma...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git

commit 7b51c5d69fecdf90939b7adad30615aa913575c1
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Oct 26 19:25:05 2020 +0000

    Add support for specifying Java 16 with the JDT compiler
---
 java/org/apache/jasper/compiler/JDTCompiler.java | 11 +++++++++++
 webapps/docs/changelog.xml                       |  6 ++++++
 2 files changed, 17 insertions(+)

diff --git a/java/org/apache/jasper/compiler/JDTCompiler.java b/java/org/apache/jasper/compiler/JDTCompiler.java
index bcb9f84..a5a5806 100644
--- a/java/org/apache/jasper/compiler/JDTCompiler.java
+++ b/java/org/apache/jasper/compiler/JDTCompiler.java
@@ -331,6 +331,11 @@ public class JDTCompiler extends org.apache.jasper.compiler.Compiler {
                 // Tomcat. May be supported in a snapshot build.
                 // This is checked against the actual version below.
                 settings.put(CompilerOptions.OPTION_Source, "15");
+            } else if(opt.equals("16")) {
+                // Constant not available in latest ECJ version shipped with
+                // Tomcat. May be supported in a snapshot build.
+                // This is checked against the actual version below.
+                settings.put(CompilerOptions.OPTION_Source, "16");
             } else {
                 log.warn(Localizer.getMessage("jsp.warning.unknown.sourceVM", opt));
                 settings.put(CompilerOptions.OPTION_Source,
@@ -417,6 +422,12 @@ public class JDTCompiler extends org.apache.jasper.compiler.Compiler {
                 // This is checked against the actual version below.
                 settings.put(CompilerOptions.OPTION_TargetPlatform, "15");
                 settings.put(CompilerOptions.OPTION_Compliance, "15");
+            } else if(opt.equals("16")) {
+                // Constant not available in latest ECJ version shipped with
+                // Tomcat. May be supported in a snapshot build.
+                // This is checked against the actual version below.
+                settings.put(CompilerOptions.OPTION_TargetPlatform, "16");
+                settings.put(CompilerOptions.OPTION_Compliance, "16");
             } else {
                 log.warn(Localizer.getMessage("jsp.warning.unknown.targetVM", opt));
                 settings.put(CompilerOptions.OPTION_TargetPlatform,
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index 706c8ee..510f851 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -121,6 +121,12 @@
         <bug>64794</bug>: Security exception reading system property on
         JspRuntimeLibrary use. (remm)
       </fix>
+      <add>
+        Add support for specifying Java 16 (with the value <code>16</code>) as
+        the compiler source and/or compiler target for JSP compilation. If used
+        with an ECJ version that does not support these values, a warning will
+        be logged and the latest supported version will used. (markt)
+      </add>
     </changelog>
   </subsection>
   <subsection name="Web applications">


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org