-
Notifications
You must be signed in to change notification settings - Fork 215
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix JDK9 #321
Fix JDK9 #321
Conversation
There was a lot of discussion on PR #272 about which version to support and the difference between immutable (unqualified "unmodifiable" in Java SE parlance) and unmodifiable view collections when moving away from Guava's immutable collections. iirc, the decision to go with JDK 10 (we thought they were 9 which is on me) was that the .of and .copyOf factories recognize each others outputs and so one can pass a collection through multiple layers that defensively copy without incurring the cost of those copies multiple times. I have no opinion on JDK 9 vs 10. They both are post-modules. I'd be happy to just go straight from JDK6 support in the last release to JDK 10. |
For me moving to 10 would be fine, however, apache common mostly still support JDK8. The question is what JDKs are targeted by the users of java-html-sanitizer (cf. #301 (comment)) |
All my (private) projects are using JDK17, but as a library I suppose you have to swallow a pill and consider JDK8 (until there is enough pressure for everyone to use modern JDKs)... |
Signed-off-by: Sven Strickroth <email@cs-ware.de>
For the compiler --release check to work, we need a more recent maven-compiler-plugin version (at least 3.6). Signed-off-by: Sven Strickroth <email@cs-ware.de>
It would also be possible to implement our own read-only wrapper for Map, Set and List and easily get "one copy", but is it worth this for people who use such old JDKs? Also, the builder shouldn't be used that frequently. |
Any news on this? |
This make the build work with JDK9
Another PR for JDK8 is on the way soon if you are interested...