Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 42328 - assign parameter to new field should declare field final [quick assist]
Summary: assign parameter to new field should declare field final [quick assist]
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: 3.0 M9   Edit
Assignee: Martin Aeschlimann CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-09-01 08:25 EDT by Nikolay Metchev CLA
Modified: 2011-05-02 03:51 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nikolay Metchev CLA 2003-09-01 08:25:37 EDT
When using the quick assist to assign to a new field from a constructor 
parameter it would be nice if the field created was final. The fields can be 
safely declared final around 99% of the time.
Comment 1 Martin Aeschlimann CLA 2004-04-29 11:19:31 EDT
fixed > 20040429
Comment 2 John Hendrikx CLA 2007-09-03 09:20:52 EDT
Version: 3.3.0
Build id: I20070621-1340

Choosing Quick Fix "Assign parameter to new field" no longer adds the final keyword, and I cannot find any place to configure this, nor any bug report where the reason was explained why this was removed.  Could this be reopened?
Comment 3 John Hendrikx CLA 2007-09-03 09:24:05 EDT
Ignore my previous comment.  The missing final keyword was caused by having a misspelled Constructor name, and quick assist was thus treating it as a normal method (with a missing return type).  I don't think older versions would offer quick fixes when there was an error like that in the code hence why I never ran into this problem before.
Comment 4 Dani Megert CLA 2011-05-02 03:51:16 EDT
See bug 130922 for people who prefer no 'final'.