Community
Participate
Working Groups
void f(String par){ String var; if ((var= par).length() == 0){} } you get a warning that var is not read. it is, however, first assigned to and then read.
No, technically, it is assigned and not read from (the stored value is dup'ed and left on the stack - this is a bytecode optimization). An assignment is only an assignment. Closing, working as expected.