Skip to content

Commit fe15159

Browse files
author
Felicity Chapman
committed
Update for feedback
1 parent fa8fd05 commit fe15159

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

java/ql/src/Violations of Best Practice/Dead Code/LocalInitialisedButNotUsed.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* @name Local variable is initialized but not used
3-
* @description Assigning a value to a local variable that is not used may indicate an error in the code.
3+
* @description A local variable that is initialized but not subsequently used may indicate an error in the code.
44
* @kind problem
55
* @problem.severity recommendation
66
* @precision low

java/ql/src/Violations of Best Practice/Dead Code/UnusedLocal.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/**
22
* @name Unused local variable
3-
* @description Assigning a value to a local variable that is not used may indicate incomplete code.
3+
* @description A local variable that is not initialized, assigned, or read may indicate incomplete code.
44
* @kind problem
55
* @problem.severity recommendation
66
* @precision low

java/ql/src/Violations of Best Practice/legacy/InexactVarArg.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ private static void length(Object... objects) {
77
public static void main(String[] args) {
88
String[] words = { "apple", "banana", "cherry" };
99
String[][] lists = { words, words };
10-
length(words); // wrong: Argument does not clarify
10+
length(words); // avoid: Argument does not clarify
1111
length(lists); // which parameter type is used.
1212
}
1313
}

java/ql/src/Violations of Best Practice/legacy/InexactVarArg.qhelp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ versions of Eclipse, the output may be:</p>
4949

5050
<sample src="InexactVarArg.java" />
5151

52-
<p>To remove this dependency on the compiler, <code>length(words)</code> should be replaced by either of the following:</p>
52+
<p>To avoid this compiler-dependent behavior, <code>length(words)</code> should be replaced by either of the following:</p>
5353

5454
<ul>
5555
<li><code>length((Object) words)</code></li>

0 commit comments

Comments
 (0)