8193819: Error message when module does not have a ModuleMainClass attribute is confusing
There's a typo in the launcher resource used for the error message when `java -m` fails because the module doesn't have a main class. The name of the attribute is "ModuleMainClass", not "MainClass". Trivial change. -Alan diff --git a/src/java.base/share/classes/sun/launcher/resources/launcher.properties b/src/java.base/share/classes/sun/launcher/resources/launcher.properties --- a/src/java.base/share/classes/sun/launcher/resources/launcher.properties +++ b/src/java.base/share/classes/sun/launcher/resources/launcher.properties @@ -220,7 +220,7 @@ Error: The JavaFX launchApplication method has the wrong signature, it\n\ must be declared static and return a value of type void java.launcher.module.error1=\ - module {0} does not have a MainClass attribute, use -m <module>/<main-class> + module {0} does not have a ModuleMainClass attribute, use -m <module>/<main-class> java.launcher.module.error2=\ Error: Could not find or load main class {0} in module {1} java.launcher.module.error3=\
+1 -Sundar On 15/02/18, 7:30 PM, Alan Bateman wrote:
There's a typo in the launcher resource used for the error message when `java -m` fails because the module doesn't have a main class. The name of the attribute is "ModuleMainClass", not "MainClass". Trivial change.
-Alan
diff --git a/src/java.base/share/classes/sun/launcher/resources/launcher.properties b/src/java.base/share/classes/sun/launcher/resources/launcher.properties --- a/src/java.base/share/classes/sun/launcher/resources/launcher.properties +++ b/src/java.base/share/classes/sun/launcher/resources/launcher.properties @@ -220,7 +220,7 @@ Error: The JavaFX launchApplication method has the wrong signature, it\n\ must be declared static and return a value of type void java.launcher.module.error1=\ - module {0} does not have a MainClass attribute, use -m <module>/<main-class> + module {0} does not have a ModuleMainClass attribute, use -m <module>/<main-class> java.launcher.module.error2=\ Error: Could not find or load main class {0} in module {1} java.launcher.module.error3=\
participants (2)
-
Alan Bateman
-
Sundararajan Athijegannathan