Index: src/v8natives.js |
diff --git a/src/v8natives.js b/src/v8natives.js |
index 4ba546b0fbca1765dd631af96f2c7ec0ef81759a..c1af69a46928eb3a55d495898d4a8bfc64fb7569 100644 |
--- a/src/v8natives.js |
+++ b/src/v8natives.js |
@@ -976,12 +976,9 @@ function DefineOwnProperty(obj, p, desc, should_throw) { |
} |
-// ES5 section 15.2.3.2. |
+// ES6 section 19.1.2.9 |
function ObjectGetPrototypeOf(obj) { |
- if (!IS_SPEC_OBJECT(obj)) { |
- throw MakeTypeError("called_on_non_object", ["Object.getPrototypeOf"]); |
- } |
- return %_GetPrototype(obj); |
+ return %_GetPrototype(TO_OBJECT_INLINE(obj)); |
} |
// ES6 section 19.1.2.19. |