Comments (13)
You can run the compiler with JDK 17, but you cannot use Java 17 language features. Those will be added in GWT 2.12 and the progress is tracked here: #9869
from gwt.
Since source level 17 is not available with gwt 2.11.0 and AFAIK if you do not set a value it should resolve to source level 1.8, you're left with one choice....
For what is worth in my configs I am setting the source level to 11
PS: but I do see your pointDo you mean, it won't support java17 compiler? Our project is upgrading to java17 so, all its modules should be compiled by 17 only. I just want to make sure why it's not allowing to compile in "17" even though it was mentioned in GWT release document.
You can use JDK 17 to compile your project and also use it to start the GWT compiler. The sourceLevel
argument defines which Java language features the GWT compiler will accept while compiling your Java code to JavaScript. That is independent of the JVM you are using to compile your app and run the GWT compiler.
from gwt.
Note: I don't want to pass -sourceLevel 11 argument to compile on 17
Why not?
from gwt.
Closing the issue because -sourceLevel 17
is expected to fail with GWT 2.11 as GWT only understands language features up to Java 11.
from gwt.
What is the actual error?
from gwt.
Error is getting as below then stops the compilation.
Source level must be one of [auto, 1.8, 9, 10, 11].
Google Web Toolkit 2.11.0
![image](https://private-user-images.githubusercontent.com/12693939/307026607-df2e35b2-5a28-45cb-8886-045e722289f9.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTc1MzQwMDMsIm5iZiI6MTcxNzUzMzcwMywicGF0aCI6Ii8xMjY5MzkzOS8zMDcwMjY2MDctZGYyZTM1YjItNWEyOC00NWNiLTg4ODYtMDQ1ZTcyMjI4OWY5LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MDQlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjA0VDIwNDE0M1omWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWExOWM5M2Y0N2ZkZGYzMGRkYmYzOGFmNzA5MWFmZDA3Yzg4NjY5Njk0NmE0NTQ0NzQyZDdlM2U5YTRkYTZmZjcmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.CpVdKdQB_gDdpkjctCtSJ9E1ine6bEq7PhcL7CaU5iw)
from gwt.
btw: are u using GIN?
from gwt.
btw: are u using GIN?
No
from gwt.
Note: I don't want to pass -sourceLevel 11 argument to compile on 17
Why not?
Don't want to bypass the java17 compiler.
from gwt.
Since source level 17 is not available with gwt 2.11.0 and AFAIK if you do not set a value it should resolve to source level 1.8, you're left with one choice....
For what is worth in my configs I am setting the source level to 11
According to @niloc132 in order to get the new lang features you'll have to set source level to either auto or 11
PS: but I do see your point
from gwt.
Since source level 17 is not available with gwt 2.11.0 and AFAIK if you do not set a value it should resolve to source level 1.8, you're left with one choice....
For what is worth in my configs I am setting the source level to 11
PS: but I do see your point
Do you mean, it won't support java17 compiler?
Our project is upgrading to java17 so, all its modules should be compiled by 17 only.
I just want to make sure why it's not allowing to compile in "17" even though it was mentioned in GWT release document.
from gwt.
Also see this gitter thread
from gwt.
Thank you all for your support and quick response.
from gwt.
Related Issues (20)
- StackTraceDeobfuscator sometimes produces total nonsense HOT 11
- Regression in jsinterop varargs causing internal compiler error HOT 3
- Tutorial: webAppCreator deprecated but necessary for tutorials HOT 2
- Need a method to run DevMode on systems without GUI support HOT 1
- SuperDevListener is not correctly build includeJsInteropExports/excludeJsInteropExports args
- Issue with tomcat version of GWT 2.11 for class javax.validation.Path HOT 8
- JDK 17 and GIN HOT 16
- SDM BindException: Address already in use
- GWT compiling issue in java 11 HOT 2
- Spurious incremental CompilerTest failure
- GWT 2.11 and Jetty 9.4.54.v20240208 error running in IntelliJ 2024.1 Ultimate HOT 3
- SDM (Super Dev Mode) does not work with a strong CSP (Content Security Policy)
- Draft compile with compiler.stackMode=strip seems to break stack trace deobfuscation with sourcemaps HOT 1
- Upgrade to HtmlUnit 3.9.0 or 4.1.0 HOT 2
- Upgrade icu4j to a version > 63.1
- Memory leak in stored exceptions HOT 8
- Issue with com.google.gwt.i18n.client.TimeZone in GWT 2.11 for Africa/Cairo Time Zone HOT 4
- Add Java 9 BigInteger methods sqrt and sqrtAndRemainder
- GWT from 2.9 to 2.11 Migration Issue Could not find com.google.gwt:gwt-codeserver:2.11.0. HOT 1
- Remove onLoadErrorFn/onPropertyErrorFn, or make them easier to disable
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gwt.