Eclipse 2021-06: ClassFormatError accessible: module java.base does not “opens java.lang” to unnamed module

Thanks, @howlger it was Lombok plug-in when using JDK 16.
That tweet gave me the reasons: https://github.com/projectlombok/lombok/issues/2810

A workaround :

  • Use Java 15 to start Eclipse or
  • add --illegal-access=warn and --add-opens=java.base/java.lang=ALL-UNNAMED to your eclipse.ini
  • or install a pre-built version (1.18.21)

In my situation I had to change eclipse.ini VM path:

-vm
C:\bin\jdk-15.0.2\bin

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)