[Solved] Error occurred during initialization of boot layer

[Exception description]

Error occurred during initialization of boot layer
java.lang.module.FindException: Error reading module: E:\Users\Administrator\eclipse-workspace\Example0\bin
Caused by: java.lang.module.InvalidModuleDescriptorException: helloMyJava.class found in top-level directory (unnamed package not allowed in module)

JDK version: 10.0.2

 

Method 1: Create a new package, drag the class files in the default package into the new package, refresh, the default package will disappear

 

Method 2: Delete module-info.java

 

Similar Posts: