kemitix-checkstyle-ruleset/builder/src/main/resources/rules/InnerAssignment.md

14 lines
227 B
Markdown
Raw Normal View History

Checks for assignments within an expressions. However, it still allows assignment in a while loop clause.
Valid:
````
while((line = reader.readLine()) != null) {
}
````
Invalid:
````
String s = Integer.toString(i = 2);
````