JaroslavTulach commented on a change in pull request #2372:
URL: https://github.com/apache/netbeans/pull/2372#discussion_r490434909



##########
File path: 
platform/api.scripting/test/unit/src/org/netbeans/api/scripting/JavaScriptEnginesTest.java
##########
@@ -256,7 +256,7 @@ public void allowLoadAClassInJS() throws Exception {
         // BEGIN: 
org.netbeans.api.scripting.JavaScriptEnginesTest#allowLoadAClassInJS
         Object fn = engine.eval("(function(obj) {\n"
                 + "  var Long = Java.type('java.lang.Long');\n"
-                + "  return new Long(33);\n"
+                + "  return new Long(\"33\");\n"

Review comment:
       Is this change really necessary? It does work in the GraalVM 20.2.0 
console (CCing @woess):
   ```bash
   ./graalvm-ce-java8-20.2.0/bin/js --jvm
   > let Long = Java.type("java.lang.Long");
   > new Long(33)
   33
   > new Long("33")
   33
   ```
   It would be surprising that the interop behaves differently in the console 
and in our `ScriptEngine`...




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to