diff --git a/java/java-impl/resources/inspectionDescriptions/ConvertToBasicLatin.html b/java/java-impl/resources/inspectionDescriptions/ConvertToBasicLatin.html index 7cfb1741f33c..c0d7c2321ef9 100644 --- a/java/java-impl/resources/inspectionDescriptions/ConvertToBasicLatin.html +++ b/java/java-impl/resources/inspectionDescriptions/ConvertToBasicLatin.html @@ -1,7 +1,9 @@
-Reports non-Basic Latin characters in literals and suggests replacing them with unicode entities. -Example:
+Reports non-Basic Latin characters in literals and comments. +The inspection provides a fix to replace such characters with Unicode escapes in literals, +and with HTML entities in comments. +Example:
// © 2021
char c = '©';
@@ -14,5 +16,7 @@ Reports non-Basic Latin characters in literals and suggests replacing them with
char c = '\u00a9';
String s = "\u00c1\u00ee";
+
+By default, this inspection does not highlight in the editor, but only provides a fix.
\ No newline at end of file
diff --git a/java/java-impl/resources/inspectionDescriptions/PrimitiveArrayArgumentToVariableArgMethod.html b/java/java-impl/resources/inspectionDescriptions/PrimitiveArrayArgumentToVariableArgMethod.html
index 500243412081..e228e18aee7e 100644
--- a/java/java-impl/resources/inspectionDescriptions/PrimitiveArrayArgumentToVariableArgMethod.html
+++ b/java/java-impl/resources/inspectionDescriptions/PrimitiveArrayArgumentToVariableArgMethod.html
@@ -1,10 +1,9 @@
-Reports any calls to a variable arity method where the call has a primitive array in
-the variable arity parameter position (for example, System.out.printf("%s", new int[]{1, 2, 3})).
-Such a primitive-array argument may be confusing, as it will be wrapped as a single-element array, rather than each individual
-element being boxed, as might be expected.
-
+Reports any calls to a variable arity method where the call has one primitive-type array in
+the variable arity parameter position.
+Such a primitive-array argument may be confusing, as it will be wrapped in a single-element array argument, rather than each
+element being a separate argument, as may be expected.
Example:
String.format("%s", new int[]{1, 2, 3});
@@ -13,5 +12,6 @@ element being boxed, as might be expected.
String.format("%s", (Object) new int[]{1, 2, 3});
+
\ No newline at end of file
diff --git a/java/java-impl/resources/inspectionDescriptions/RedundantCast.html b/java/java-impl/resources/inspectionDescriptions/RedundantCast.html
index 331cc61e5f89..9d169063cd84 100644
--- a/java/java-impl/resources/inspectionDescriptions/RedundantCast.html
+++ b/java/java-impl/resources/inspectionDescriptions/RedundantCast.html
@@ -1,16 +1,21 @@
Reports unnecessary cast expressions.
-
-Example:
+Example:
static Object toObject(String s) {
return (Object) s;
}
+After the quick-fix is applied:
+
+ static Object toObject(String s) {
+ return s;
+ }
+
- Use the checkbox below to ignore clarifying casts e.g., casts in collection calls where Object is expected:
+ Use the checkbox below to ignore clarifying casts, for example casts in collection calls where Object is expected:
static void removeFromList(List<String> l, Object o) {
l.remove((String)o);
diff --git a/java/java-impl/resources/inspectionDescriptions/TrailingWhitespacesInTextBlock.html b/java/java-impl/resources/inspectionDescriptions/TrailingWhitespacesInTextBlock.html
index 80dfc81c9d5d..55d32194472a 100644
--- a/java/java-impl/resources/inspectionDescriptions/TrailingWhitespacesInTextBlock.html
+++ b/java/java-impl/resources/inspectionDescriptions/TrailingWhitespacesInTextBlock.html
@@ -2,6 +2,23 @@
Reports text blocks with trailing whitespace characters.
Trailing whitespace is considered incidental and will be stripped away by the Java compiler.
+Example (where spaces are indicated with dots):
+
+..String.count.=."""
+....one
+....two....
+....three
+....""";
+
+Two quick-fixes are provided.
+ One to remove the trailing whitespace, and one to escape the trailing whitespace so that it will not be removed by the compiler:
+
+..String.count.=."""
+....one
+....two...\s
+....three
+....""";
+
New in 2021.1
diff --git a/java/java-impl/resources/inspectionDescriptions/UnnecessaryStringEscape.html b/java/java-impl/resources/inspectionDescriptions/UnnecessaryStringEscape.html
index 7f676be37896..d4f983e4ee82 100644
--- a/java/java-impl/resources/inspectionDescriptions/UnnecessaryStringEscape.html
+++ b/java/java-impl/resources/inspectionDescriptions/UnnecessaryStringEscape.html
@@ -1,7 +1,9 @@
-Reports unnecessarily escaped characters in String and optionally char literals.
-Escaped tab characters \t are not reported, because tab characters are invisible.
+Reports unnecessarily escaped characters in String literals,
+and optionally char literals.
+Escaped tab characters (\t) are not reported, even though escaping them is not required,
+because tab characters are hard to tell apart from spaces.
Examples:
String s = "\'Scare\' quotes";
@@ -14,9 +16,8 @@ Reports unnecessarily escaped characters in String and optionally <
String t = """
All you need is
\tLove
- """;
+ """;
-New in 2019.3
\ No newline at end of file