-
Notifications
You must be signed in to change notification settings - Fork 586
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
[4.8.0] DM_DEFAULT_ENCODING for UTF-8 spec'd methods #2634
Comments
Please revert #2516. It was completely wrong in it’s premise. |
Contrary to what was repored in spotbugs#2114 and as noted in spotbugs#2634, methods added in JDK 11 are using UTF-8 (not the default charset)
For the completeness, link to Java 11 API: https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/nio/file/Files.html#readString(java.nio.file.Path) Quote
|
The
java.nio.file.Files
methodsreadString(f)
andwriteString(f, str)
are documented to useUTF-8
and do not rely on the default platform encoding. There is no need to specify the charset directly, unlike the legacy file i/o.The text was updated successfully, but these errors were encountered: