This page is no longer maintained — Please continue to the home page at www.scala-lang.org

Intellij IDEA 11 is well worth a look

3 replies
Ken McDonald
Joined: 2011-02-13,
User offline. Last seen 42 years 45 weeks ago.
I couldn't find any general comments on IDEA 11, so thought I would post mine. Of course, if Eclipse is working well for you, just disregard this :-)
I always found IDEA 10+Scala plugin more useable than the various Eclipse plugin versions I tried, but IDEA 10 was nonetheless quite flawed when handling Scala. Version 11 is a huge improvement. Much faster, far fewer spurious errors (it still doesn't fully understand implicit conversions and will flag as type errors values that will be converted via implicits), much easier to get run/test configurations set up. The idea-sbt plugin seems to work without problems. The UI in general has been cleaned up somewhat.
A few caveats. I'm not pushing things hard, i.e. smallish projects, no multimodule projects, etc. So I can't comment on how well IDEA will stand up to "big iron" usage. Also, there was a comment in Scala-user noting issues with the debugger, which may or may not be resolved by a plugin by this time; I don't use the debugger (I prefer writing unit tests to track down errors), so I can't offer feedback on this.
But, all in all, it's obvious that IDEA is making major progress in its support for Scala (I suspect the same is true of Eclipse), and that's good news for the entire community. Even if you use Eclipse :-).
Cheers,Ken
H-star Development
Joined: 2010-04-14,
User offline. Last seen 2 years 26 weeks ago.
Re: Intellij IDEA 11 is well worth a look

-------- Original-Nachricht --------
> Datum: Tue, 27 Dec 2011 23:00:06 -0800 (PST)
> Von: Ken McDonald
> An: scala-user [at] googlegroups [dot] com
> Betreff: [scala-user] Intellij IDEA 11 is well worth a look

> I couldn't find any general comments on IDEA 11, so thought I would post
> mine. Of course, if Eclipse is working well for you, just disregard this
> :-)

i tried both. last time i checked, eclipse had better (less false positives) error highlighting and faster compilation, idea has better analysis, coding assistance and general highlighting features (configurable color/marking style for val, var, local, field, parameter, implicit, object and what else is there - idea is able to add information to the code without modifying it which in turn makes it a LOT easier to read if conversions are involved.

>
> I always found IDEA 10+Scala plugin more useable than the various Eclipse
> plugin versions I tried, but IDEA 10 was nonetheless quite flawed when
> handling Scala. Version 11 is a huge improvement. Much faster, far fewer
> spurious errors (it still doesn't fully understand implicit conversions
> and
> will flag as type errors values that will be converted via implicits),
> much
> easier to get run/test configurations set up. The idea-sbt plugin seems to
> work without problems.

never tried, i use the fsc which now also works without problems and is managed by idea in the background.

The UI in general has been cleaned up somewhat.
>
> A few caveats. I'm not pushing things hard, i.e. smallish projects, no
> multimodule projects, etc. So I can't comment on how well IDEA will stand
> up to "big iron" usage.

i had a project with 500 files (compiled to 2500 classes). as long as you keep your files small, there should be no problem. big files seem to be a bigger problem than lots of classes.
multimodule works.

Also, there was a comment in Scala-user noting
> issues with the debugger, which may or may not be resolved by a plugin by
> this time; I don't use the debugger (I prefer writing unit tests to track
> down errors), so I can't offer feedback on this.

what works, works fine. what does not, does not. they have a blog with a list of working features.

>
> But, all in all, it's obvious that IDEA is making major progress in its
> support for Scala (I suspect the same is true of Eclipse), and that's good
> news for the entire community. Even if you use Eclipse :-).
>
> Cheers,
> Ken

Sciss
Joined: 2008-12-17,
User offline. Last seen 28 weeks 5 days ago.
Re: Intellij IDEA 11 is well worth a look

the debugger is pretty cool, i use it a lot, it got much smarter with regard to single step avoiding non-scalaish branching. there are only few issues (if you use conditional breakpoints, your local variable might be called 'i$1' instead of 'i', but in any case IDEA will warn you if the name is wrong and stop there, so you can adjust) which don't affect the experience much.

overall the false positive errors have gone down a lot, occasionally i find myself adding a type annotation which fixes some of them (not all, though). the yellow warnings are a great help and you can fully customise which ones you want to see and which not. unused objects are greyed out, again a great feature (the only wrong ones i got so far are importing implicits sometimes). refactorings like renaming of arguments, fields, methods, classes, types work super reliable.

i mostly keep sbt running in ~test:compile with IDEA's sbt plugin, it's great and you get the hyperlinks for all the errors. i stopped fiddling with the project settings at all. if i change a library version or so, i just re-create the idea project with the sbt-idea plugin ( https://github.com/mpeltonen/sbt-idea ), and copy my project prefs template to it (Settings -> Code Style -> Set From...).

the new interactive console (Scala Console Run-Config) is great, as it's a spiced up REPL with all the autocompletion stuff that you know from the normal code editor.

in the rare cases where the machine heats up, you can still turn the inspector to power-safe mode, so there are really no obstacles with larger files (>2k loc per file i would say). i don't use the structure view, though, (you got so many nice other helpers, like the search tool is very good, and also the vertical lines for the structural indents which reveal the block's first line when you move the cursor onto it) -- so can't comment on that (it used to slow down things, but i haven't verified that with the current version).

finally, i _love_ the blue forest colour scheme ( https://github.com/sirthias/BlueForest ), definitely worth checking out!

and it's constantly improving (i just realised it recognises errors in the scaladoc parameters now)

best, -sciss-

On 28 Dec 2011, at 08:00, Ken McDonald wrote:

> I couldn't find any general comments on IDEA 11, so thought I would post mine. Of course, if Eclipse is working well for you, just disregard this :-)
>
> I always found IDEA 10+Scala plugin more useable than the various Eclipse plugin versions I tried, but IDEA 10 was nonetheless quite flawed when handling Scala. Version 11 is a huge improvement. Much faster, far fewer spurious errors (it still doesn't fully understand implicit conversions and will flag as type errors values that will be converted via implicits), much easier to get run/test configurations set up. The idea-sbt plugin seems to work without problems. The UI in general has been cleaned up somewhat.
>
> A few caveats. I'm not pushing things hard, i.e. smallish projects, no multimodule projects, etc. So I can't comment on how well IDEA will stand up to "big iron" usage. Also, there was a comment in Scala-user noting issues with the debugger, which may or may not be resolved by a plugin by this time; I don't use the debugger (I prefer writing unit tests to track down errors), so I can't offer feedback on this.
>
> But, all in all, it's obvious that IDEA is making major progress in its support for Scala (I suspect the same is true of Eclipse), and that's good news for the entire community. Even if you use Eclipse :-).
>
> Cheers,
> Ken

Donald McLean
Joined: 2009-11-11,
User offline. Last seen 2 years 48 weeks ago.
Re: Intellij IDEA 11 is well worth a look

My experience has been the more carefully and thoroughly you document
any problems, the quicker they get fixed. The Scala folks at JetBrains
have been making steady progress at eliminating the false positives
and the occasional false negative BUT they can't fix problems that
they don't know about.

Not that it matters to me - I loathe the Eclipse UI.

Donald

Copyright © 2012 École Polytechnique Fédérale de Lausanne (EPFL), Lausanne, Switzerland