Mostly I have had great results with mixed code - however, occasionally I will mess with some java code, and then an unrelated java class will stop compiling - as it is unable to find the scala class it depends on (not talking circular deps or anything fancy). Note that it won't show up with syntax errors (even the content assistance works correctly) but it just wont "make" when I try to build it, or run tests.

I use maven to build as well, and it is able to build correctly (even a clean build).

To correct - I usually comment out the offending bits, make, and then restore it and all is well.

By "rebuild from scratch" I meant just full rebuild. If problem relates to our compiler caches it might help. But, as I understood, this problem is foation, i.e. you cannot reproduced it by fixed sequence of steps?

Hi Ilya. OK I can reproduce it - I have created an issue: http://www.jetbrains.net/jira/browse/SCL-541 with the attached project that shows it (I hope others are able to see this).I did update to the latest scala plugin just this morning, and it is still happening.

Hope this sheds some light (note I can build fine with maven + scala plug in for it - so the code should be sound from scalac's point of view).

(also attached to the forum - didn't realise you could do that until I created the bug report).

It seems, the problem is in order of compilation. By default, IDEA compiles Java files first, and only after that it compiles Scala contenct. To change this order just open Settings -> Compiler -> scala Compiler dialog and mark "Compile Scala files first" checkbox.