Index: src/builtins/builtins-object.cc |
diff --git a/src/builtins/builtins-object.cc b/src/builtins/builtins-object.cc |
index 98bce48f3abe05a8232d93c6d116a512c9511165..93c43ab5db4113bca167d1e69da47742a8d8a9f8 100644 |
--- a/src/builtins/builtins-object.cc |
+++ b/src/builtins/builtins-object.cc |
@@ -1060,5 +1060,19 @@ void Builtins::Generate_InstanceOf(compiler::CodeAssemblerState* state) { |
assembler.Return(assembler.InstanceOf(object, callable, context)); |
} |
+// ES6 section 7.3.19 OrdinaryHasInstance ( C, O ) |
+void Builtins::Generate_OrdinaryHasInstance( |
+ compiler::CodeAssemblerState* state) { |
+ typedef compiler::Node Node; |
+ typedef CompareDescriptor Descriptor; |
+ CodeStubAssembler assembler(state); |
+ |
+ Node* constructor = assembler.Parameter(Descriptor::kLeft); |
+ Node* object = assembler.Parameter(Descriptor::kRight); |
+ Node* context = assembler.Parameter(Descriptor::kContext); |
+ |
+ assembler.Return(assembler.OrdinaryHasInstance(context, constructor, object)); |
+} |
+ |
} // namespace internal |
} // namespace v8 |