changeset 19090:b5cf0f877326

8021164: REGRESSION: test262 failures after JDK-8021122 Reviewed-by: jlaskey, hannesw
author sundar
date Tue, 23 Jul 2013 21:45:27 +0530
parents 51cfdcf21d35
children ed2bbb8fdcb3 e23f2618ffde
files nashorn/src/jdk/nashorn/internal/runtime/linker/Bootstrap.java
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/nashorn/src/jdk/nashorn/internal/runtime/linker/Bootstrap.java	Tue Jul 23 12:00:29 2013 -0300
+++ b/nashorn/src/jdk/nashorn/internal/runtime/linker/Bootstrap.java	Tue Jul 23 21:45:27 2013 +0530
@@ -41,6 +41,7 @@
 import jdk.nashorn.api.scripting.ScriptObjectMirror;
 import jdk.nashorn.internal.codegen.CompilerConstants.Call;
 import jdk.nashorn.internal.codegen.RuntimeCallSite;
+import jdk.nashorn.internal.runtime.JSType;
 import jdk.nashorn.internal.runtime.ScriptFunction;
 import jdk.nashorn.internal.runtime.ScriptRuntime;
 import jdk.nashorn.internal.runtime.options.Options;
@@ -102,7 +103,7 @@
      * @return true if the obj is an instance of @FunctionalInterface interface
      */
     public static boolean isFunctionalInterfaceObject(final Object obj) {
-        return obj != null && (NashornBottomLinker.getFunctionalInterfaceMethod(obj.getClass()) != null);
+        return !JSType.isPrimitive(obj) && (NashornBottomLinker.getFunctionalInterfaceMethod(obj.getClass()) != null);
     }
 
     /**