Using Intellij IDEA with current JDK
aph at redhat.com
Thu Jan 18 17:59:58 UTC 2018
On 17/01/18 17:47, David Lloyd wrote:
> What I've done is to force no JDK at all. It does present an ugly
> banner at the top but otherwise it seems to work fine - or did,
> until the latest update. If you've already set up a SDK, I think
> there's no way to unset it, so you have to close IDEA, edit your
> xxx.ipr or .idea/modules.xml (I think) and delete the line which
> defines the SDK.
OK, I see. It works, kinda-sorta, but navigation is pretty useless,
and everything is covered with red squiggles.
>  See also: https://youtrack.jetbrains.com/issue/IDEA-142878
>  The error I see at present is of the type "Package 'java.lang' is
> in the unnamed module, but module 'jdk.compiler' does not read it".
> Previously I had excluded module-info.java from all source roots, but
> the latest update somehow determines that everything are Java 9
> modules anyway. I had done this for two reasons: firstly, there are
> not module descriptors in every place where there are sources (for
> example, having a separate "java.base:share" and "java.base:unix" IDEA
> module causes problems because :share has a module-info.java but :unix
> does not), and secondly, IDEA does not cope well with situations where
> there is more than one module-info.java (for example if one is
> generated from the other) or if it is simply generated to begin with.
OK, I'm starting to understand some of the problems. Thanks.
Java Platform Lead Engineer
Red Hat UK Ltd. <https://www.redhat.com>
EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671
More information about the jdk-dev