| Summary: | Save action "remove redundant modifiers" remove non-redundant modifier | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Clovis Seragiotto <clovis.seragiotto> |
| Component: | UI | Assignee: | JDT-UI-Inbox <jdt-ui-inbox> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | noopur_gupta |
| Version: | 4.12 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows 10 | ||
| Whiteboard: | |||
Please try with Eclipse 2019-09 release build as I don't see this issue. The behavior cannot be reproduced with Eclipse 2019-09. |
When saving the following code, the modifier "final" (which is not redundant) is removed if the save action "Remove redundant modifiers" is on. var o = new Object() { final int i = 1; }; Even funnier: if the save action "add final modifier to private fields" is also on, then for var o = new Object() { private int i = 1; }; you see that the final modifier is added and immediately removed.