| Summary: | [encapsulate field] Encapsulating parenthesized field with unary operator yields compilation error | ||
|---|---|---|---|
| Product: | [Eclipse Project] JDT | Reporter: | Brett Daniel <bdaniel3> |
| Component: | UI | Assignee: | JDT-UI-Inbox <jdt-ui-inbox> |
| Status: | CLOSED DUPLICATE | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | daniel_megert |
| Version: | 3.3 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Whiteboard: | |||
*** This bug has been marked as a duplicate of bug 177095 *** |
Build ID: I20070222-0951 Steps To Reproduce: Encapsulate field f on the following: public class A { int f; void m(){ (f)++; } } Yields the following refactored code: public class A { private int f; void m(){ (getF())++; } public void setF(int f) { this.f = f; } public int getF() { return f; } } Note that "(getF())++;" is a compilation error. Bug also appears for prefix operators. More information: