This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
It should be possible to have a main class in an unnamed package. I am Working with JDK9 build . If I create a new project and add a new java class in *default* package..this project though compiles but does not run. This is because it tries to call the generated jar as if it were an automatic module. output after clean and build on my machine is : To run this application from the command line without Ant, try: /Users/RachnaGoel/jdk/dev/build/macosx-x64/images/jdk/bin/java --module-path /Users/RachnaGoel/NetBeansProjects/JavaLibrary1/dist/JavaLibrary1.jar -cp /Users/RachnaGoel/NetBeansProjects/JavaLibrary1/dist/JavaLibrary1.jar newpackage.NewClass As it is clear, we can not use --module-path when the jar contains a class in the unnamed package. This is an issue with Netbeans 21st october 2016 Dev build.