Bug 495976 - Autocomplete shall show enum values for enum parameters
Summary: Autocomplete shall show enum values for enum parameters
Status: NEW
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 4.6   Edit
Hardware: PC Windows 7
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-Core-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-13 06:29 EDT by Frank Benoit CLA
Modified: 2016-06-14 05:01 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frank Benoit CLA 2016-06-13 06:29:32 EDT
Using 4.6RC3:

Given this code:

enum State { ON, OFF; }
public void take( State state ) {}

public void test() {
    take(<cursor>)
}

When the cursor is in the marked location, the auto completion or Ctrl-space should give the available values for selection. E.g. i choose "ON", it expands to:
    take(State.ON)<cursor>

The needed import for the enum might be imported.
Comment 1 Jay Arthanareeswaran CLA 2016-06-14 04:00:03 EDT
This behavior has been the same forever. Marking as enhancement.
Comment 2 Frank Benoit CLA 2016-06-14 05:01:32 EDT
yes, it was meant as enhancement request.
Thanks