Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 349697

Summary: compiler setting mismatch between global and project
Product: [Eclipse Project] JDT Reporter: Missing name <horn>
Component: CoreAssignee: Jay Arthanareeswaran <jarthana>
Status: CLOSED WONTFIX QA Contact:
Severity: major    
Priority: P3 CC: bobbamme, jarthana, Olivier_Thomann
Version: 3.6.2   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard: stalebug
Attachments:
Description Flags
screenshot showing compiler compliance setting in project and global preferences
none
Workspace that will show the problem
none
prefs file that triggers the problem none

Description Missing name CLA 2011-06-17 11:29:28 EDT
When Eclipse is started I get errors that compiler compliance level doesnt match the project facet.
I have set compliance level in preferences manually to 1.5 and in project which doesnt override the setting
it is showing compliance level 1.4(will attach screenshot).

-- Configuration Details --
Product: Eclipse SDK 3.6.2.v201102101200 (org.eclipse.sdk.ide)
Installed Features:
 org.eclipse.jdt 3.6.2.r362_v20101117-0800-7z8XFW6FLFlmjJcvz03jyeFBLS_F
Comment 1 Missing name CLA 2011-06-17 11:31:32 EDT
Created attachment 198188 [details]
screenshot showing compiler compliance setting in project and global preferences
Comment 2 Olivier Thomann CLA 2011-06-17 11:40:18 EDT
Jay, please investigate.

Horn, could you please check with 3.7RC5? Thanks.
Comment 3 Jay Arthanareeswaran CLA 2011-06-20 01:17:08 EDT
I tried with 3.7 RC4 and this is what I found. 

I set the global compliance level to 1.6, came back to the project with 1.5 code (generics) and set the compliance to 1.4. Obviously the code with 1.5 code shows errors. When I disabled the project specific settings, it still shows the compliance drop-down as 1.4, albeit deactivated. But this is only temporary and not a problem at all as the moment I click 'OK' or 'Apply' the code is recompiled and the errors go away.

If I close the preference dialog and open again, it properly picks the values from the global settings.

So, I don't think this is a bug. Please confirm.
Comment 4 Jay Arthanareeswaran CLA 2011-06-20 02:15:45 EDT
Found the same behavior on previous builds as well.
Comment 5 Missing name CLA 2011-06-23 08:46:46 EDT
This bug still happens in indigo.
What Mr. Arthanareeswaran tested is not what I reported.
I clearly stated that this happens at eclipse startup.
No project properties had been edited at this point.
I can manually override the defaults and the error will go away by checking the project setting checkbox and choosing 1.5 compliance.
I can even uncheck this checkbox and the compliance level stays at 1.5
but as soon as I restart eclipse and try to build the project the error will reappear.

Even if it were what I reported this would be still a bug albeit only a cosmetical one.
This dialog should show one of 2 states:
with the checkbox off it should show global settings
with the checkbox on it show the current project settings
Comment 6 Jay Arthanareeswaran CLA 2011-06-27 09:51:46 EDT
I don't see the reported behavior with 3.7.
Moving to JDT/UI for confirmation and investigation if it's still an issue.
Comment 7 Missing name CLA 2011-07-12 11:11:31 EDT
Created attachment 199506 [details]
Workspace that will show the problem
Comment 8 Missing name CLA 2011-07-12 11:14:27 EDT
Created attachment 199507 [details]
prefs file that triggers the problem

I copied the attached prefs file from my problem workspace to a new test workspace(also attached) in order to reproduce the problem.
My problem workspace has been migrated from Eclipse 3.6 to Eclipse 3.7.
Comment 9 Jay Arthanareeswaran CLA 2011-10-05 11:55:47 EDT
Thanks for the workspace. I still can't reproduce the problem, though. Can you please tell me what JRE you have on your environment and what is your default JRE or execution environment?
Comment 10 Missing name CLA 2011-10-06 05:30:22 EDT
I using the jre that comes with Websphere v6.1 in Rational Application Developer 7.0.0.10.
The version string is the following:
java version "1.5.0"
Java(TM) 2 Runtime Environment, Standard Edition (build pwi32devifx-20110211a (S
R12 FP3 +IZ94331))
IBM J9 VM (build 2.3, J2RE 1.5.0 IBM J9 2.3 Windows XP x86-32 j9vmwi3223ifx-2010
1130 (JIT enabled)
J9VM - 20101129_69669_lHdSMr
JIT  - 20100623_16197ifx1_r8
GC   - 20100211_AA)
JCL  - 20110208

I am using Oracle JDK 1.6.0_25 to start Eclipse.
Comment 11 Missing name CLA 2011-10-06 09:21:34 EDT
Do you have all the plugins esp the WTP installed?
Comment 12 Ayushman Jain CLA 2011-11-08 01:23:22 EST
*** Bug 362544 has been marked as a duplicate of this bug. ***
Comment 13 Eclipse Genie CLA 2019-10-22 06:44:16 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.