Bug 139674 - [quick fix] Create field if 'Assignment has no effect'
Summary: [quick fix] Create field if 'Assignment has no effect'
Status: ASSIGNED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-05-02 09:40 EDT by Benno Baumgartner CLA
Modified: 2009-01-23 11:34 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Benno Baumgartner CLA 2006-05-02 09:40:29 EDT
3.2. RC2

Given:
public void set(int i) {
   i= i;
}

Warning at i= i; 'Assignment has no effect'
1. Ctrl-1
Is:
  None available
Should:
  'Create field 'i''

Given a field 'k' and an assignment 'k= k;' offers a quick fix 'Create parameter 'k'' which is IMHO a less common use case then the other way around (top down). 

Use case: Create method (with quick fix), go there, write assignment, create field, go there, create getter, ...