Summary: | [preferences][quick fix] Compiler compliance auto-detection | ||||||
---|---|---|---|---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | Patrick Julian <mail.recycling> | ||||
Component: | UI | Assignee: | JDT-UI-Inbox <jdt-ui-inbox> | ||||
Status: | ASSIGNED --- | QA Contact: | |||||
Severity: | enhancement | ||||||
Priority: | P3 | CC: | daniel_megert, markus.kell.r, pwebster | ||||
Version: | 4.2 | ||||||
Target Milestone: | --- | ||||||
Hardware: | All | ||||||
OS: | All | ||||||
Whiteboard: | |||||||
Attachments: |
|
Hint: If you use an "Execution environment" as JRE System Library, then the correct compiler compliance is automatically set when you change to a different EE. I know that's not exactly what you asked for, but that's the recommended way. Hello Markus. Yes, the dialog mentioned by you (assuming you mean this: http://help.eclipse.org/juno/index.jsp?topic=%2Forg.eclipse.jdt.doc.user%2FgettingStarted%2Fqs-with-java7.htm) actually got me thinking about this issue. So the detection logic seems to be present in Eclipse but as-for-now it is kind of "hidden" in the sub-dialog while the main JRE settings page remains as I have described initially. I think it would be worth investing in usability improvements here, because the multitude of available Java, JRE and JDK versions can be pretty confusing for newbies and I bet it's helpful to have some assistance here. Especially as this is not going to become simpler in future, because even more (new) Java versions will become available over time. |
Created attachment 239107 [details] Current behaviour Current behaviour: I want to set the compiler compliance level in Preferences > Java > Compiler. I set it to 1.6, for example. Eclipse issues a warning (!) that I need a compatible JRE. Expected behaviour: - Eclipse should be able to autodetect whether the activated JRE is compatible with the given compiler compliance level or not. - Eclipse should only warn me if the given combination really won't work. - If there must be a warning, then it should be located next to the form element that causes it to appear (not be dangling somewhere at the bottom). Best-case behaviour: - Eclipse offers to auto-fix the problem by -- checking whether a compatible JRE is installed (see above) and activating that JRE -- if that is not possible, by issuing a valid link where the user can download a JRE that is known to be compatible to the desired compliance level.