I noticed that the documentation on www.intellij.com mentions that IDEA 4.0
works out of the box with the JDK 1.5 beta. This was news to me, so I
decided to try it out. The results were slightly confusing...
The claim about JDK 1.5 support seems to be correct: I was able to use
generic types when I had my project JDK set to the 1.5 beta, but the same
code was (rightly) flagged as an error when the JDK was set to 1.4.2.
All of the UI references to generics are what confuse matters. They only
seem to be relevant to the old JSR-14 compiler. What was actually required
to get 1.5 code compiling with generics is the "-source 1.5" (and,
optionally, the "-target 1.5") switch.
1. Change the wording of the "Set up generics" and "Use generics-enabled
compiler" options to make it clear that they're only relevant to the JSR-14
compiler release and not to JDK 1.5.
2. Have the IDE automatically supply the "-source 1.5" option if generics
are being used with JDK 1.5. (On a related note, it'd be nice to do
something similar for code which uses assert statements on a 1.4 or greater
email@example.com / digital steps /
(W) +44 (0)1483 469 480
(M) +44 (0)7816 678 457 http://www.digitalsteps.com/