diff --git a/src/share/classes/javax/script/ScriptEngineFactory.java b/src/share/classes/javax/script/ScriptEngineFactory.java index 9fc08a92bbd8c88073a15a89233584f34808d7d4..46b56ef66fc403785320e4feb9eba9389df6e441 100644 --- a/src/share/classes/javax/script/ScriptEngineFactory.java +++ b/src/share/classes/javax/script/ScriptEngineFactory.java @@ -152,12 +152,11 @@ public interface ScriptEngineFactory { * ret += "." + m + "("; * for (int i = 0; i < args.length; i++) { * ret += args[i]; - * if (i == args.length - 1) { - * ret += ")"; - * } else { + * if (i < args.length - 1) { * ret += ","; * } * } + * ret += ")"; * return ret; * } *