Community
Participate
Working Groups
Build 3.1rc2 The following cases could be diagnosed as having little effect: public class X { void foo() { int length1 = 0; length1 = length1; // already detected int length2 = length2 = 0; // not detected int length3 = 0; length3 = length3 = 0; // not detected } }
*** Bug 100368 has been marked as a duplicate of this bug. ***
Other case where can complain: a = ++a
Considering for 3.2. Also will take out the codegen optimizing for this scenario, which is fairly dangerous (i.e. not generating the assignment is risky, if a bug in detection of this diagnosis, it could ruin the generated code entirely as observed in bug 111898). Added AssignmentTest#test044 and tuned other affected tests.
Verified for 3.2 M6 using build I20060327-0010