Reputation: 39
I'm working on my project and the last problem is here, how can I respect the InnerAssignmentCheck at line 3?
public void add(Account account) {
if (tail == null) {
head = tail = new Node(account, null);
}
else {
tail.next = new Node(account, null);
tail = tail.next;
}
size++;
}
Upvotes: 0
Views: 517
Reputation:
Documentation of InnerAssignmentCheck
(my emphasis):
Rationale: With the exception of for iterators, all assignments should occur in their own toplevel statement to increase readability.
Upvotes: 1