Community
Participate
Working Groups
After an assignment in a brace-less if-clause, that assigns a conditional expression to a boolean variable, the indentation-level doesn't revert to normal. This can be fixed by sourrounding the conditional expression with braces, but java-syntax doesn't impose this restriction. Here it fails: boolean test; if(true) test = 4>0; int x = 4; x+=4; System.out.println("lol"); Here it works: boolean test; if(true) test = (4>0); int x = 4; x+=4; System.out.println("lol"); -- Configuration Details -- Product: Eclipse 4.7.3.20180405-1200 (org.eclipse.epp.package.java.product)Installed Features: org.eclipse.jdt 3.13.4.v20180330-0919 Versioning Plugin: org.eclipse.platform 4.7.3.v20180330-0640
I see the same thing, but the problem seems to also need a constant expression for a switch case: public class Bug { public void eInverseAdd(Object otherEnd, int featureID, Object msgs) { switch (featureID) { case 57 + 1: if (otherEnd != null) msgs = null; return; // This should be indented to match if. } return; } }
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.
Cannot be stale under a relevant committer has triaged.