changeset 456:ccbea9172aa5

8021164: REGRESSION: test262 failures after JDK-8021122 Reviewed-by: jlaskey, hannesw
author sundar
date Tue, 23 Jul 2013 21:45:27 +0530
parents e86b297d26aa
children 4cb1780bc385 8b97fe2b7c98
files src/jdk/nashorn/internal/runtime/linker/Bootstrap.java
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/jdk/nashorn/internal/runtime/linker/Bootstrap.java	Tue Jul 23 12:00:29 2013 -0300
+++ b/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);
     }
 
     /**