It should replace to Boolean.valueOf(value) if your language level is greater than 1.3 since Boolean.valueOf was introduced in jdk 1.4. Do you have the language level of your project set to 1.3? If not, which build are you using?
But, Language level is not Language :) It should be depended on JDK, not on Language level (keywords support and highlighting). I'm wrong? :)
I guess it's debatable. InspectionGadgets and IntentionPowerPack go by the principle that if you develop using language level 1.3, you want the final code to be able to run on 1.3. If the reason is you want to avoid certain language constructs, you should probably use the inspections in the category "Java language level issues".
I think this behavior sucks because it makes the IDE distinction between language level and JDK much less useful.
Bas Leijdekkers wrote:
Alexey Efimov wrote:
>> But, Language level is not Language :) It should be depended on JDK, >> not on Language level (keywords support and highlighting). I'm wrong? >> :)
I guess it's debatable. InspectionGadgets and IntentionPowerPack go by the principle that if you develop using language level 1.3, you want the final code to be able to run on 1.3. If the reason is you want to avoid certain language constructs, you should probably use the inspections in the category "Java language level issues".
A very eloquent and nuanced opinion. How would you improve it? This way it's possible to develop on java 5 and deploy on 1.4 (like IDEA itself) or vice versa avoid java 5 features but still deploy on a 5.0 vm. Is this possible any other way?
I think you're talking about that expression of my opinion. I think there should be a setting "Target JDK" which is different than "Compile JDK." Of course this might wait for http://jetbrains.net/jira/browse/IDEADEV-2853 when there's some unified UI for compile vs run (vs test) libraries.
Bas Leijdekkers wrote:
A very eloquent and nuanced opinion. How would you improve it? This way it's possible to develop on java 5 and deploy on 1.4 (like IDEA itself) or vice versa avoid java 5 features but still deploy on a 5.0 vm. Is this possible any other way?
Hi Alexy,
Alexey Efimov wrote:
It should replace to Boolean.valueOf(value) if your language level is
greater than 1.3 since Boolean.valueOf was introduced in jdk 1.4.
Do you have the language level of your project set to 1.3? If not, which
build are you using?
Bas
Ops, fixed :)
But, Language level is not Language :) It should be depended on JDK, not on Language level (keywords support and highlighting). I'm wrong? :)
Alexey Efimov wrote:
I guess it's debatable. InspectionGadgets and IntentionPowerPack go by
the principle that if you develop using language level 1.3, you want the
final code to be able to run on 1.3. If the reason is you want to avoid
certain language constructs, you should probably use the inspections in
the category "Java language level issues".
Bas
Language level is not the same as Target JDK, i guess.
So, for example, i have language level below 1.5, but IG highlight me Unnessary Unboxing on Boolean.valueOf(value).
Alexey Efimov wrote:
That would be a bug. Do you have an example?
Bas
Hmm,
Since i'm switch language level, i can't this reproduce... :)
I think this behavior sucks because it makes the IDE distinction between
language level and JDK much less useful.
Bas Leijdekkers wrote:
>> But, Language level is not Language :) It should be depended on JDK,
>> not on Language level (keywords support and highlighting). I'm wrong?
>> :)
A very eloquent and nuanced opinion. How would you improve it?
This way it's possible to develop on java 5 and deploy on 1.4 (like IDEA itself) or vice versa avoid java 5 features but still deploy on a 5.0 vm. Is this possible any other way?
Bas
I think you're talking about that expression of my opinion. I think
there should be a setting "Target JDK" which is different than "Compile
JDK." Of course this might wait for
http://jetbrains.net/jira/browse/IDEADEV-2853 when there's some unified
UI for compile vs run (vs test) libraries.
Bas Leijdekkers wrote:
Keith Lea wrote:
Ah, now I understand, and that makes sense. Is there a JIRA request I
can vote for?
Bas