| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/runtime/runtime-utils.h" | 5 #include "src/runtime/runtime-utils.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 | 8 |
| 9 #include "src/arguments.h" | 9 #include "src/arguments.h" |
| 10 #include "src/ast/prettyprinter.h" | 10 #include "src/ast/prettyprinter.h" |
| (...skipping 567 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 578 | 578 |
| 579 RUNTIME_FUNCTION(Runtime_IsWasmObject) { | 579 RUNTIME_FUNCTION(Runtime_IsWasmObject) { |
| 580 HandleScope scope(isolate); | 580 HandleScope scope(isolate); |
| 581 DCHECK_EQ(1, args.length()); | 581 DCHECK_EQ(1, args.length()); |
| 582 CONVERT_ARG_CHECKED(Object, object, 0); | 582 CONVERT_ARG_CHECKED(Object, object, 0); |
| 583 bool is_wasm_object = | 583 bool is_wasm_object = |
| 584 object->IsJSObject() && wasm::IsWasmObject(JSObject::cast(object)); | 584 object->IsJSObject() && wasm::IsWasmObject(JSObject::cast(object)); |
| 585 return *isolate->factory()->ToBoolean(is_wasm_object); | 585 return *isolate->factory()->ToBoolean(is_wasm_object); |
| 586 } | 586 } |
| 587 | 587 |
| 588 RUNTIME_FUNCTION(Runtime_Typeof) { |
| 589 HandleScope scope(isolate); |
| 590 DCHECK_EQ(1, args.length()); |
| 591 CONVERT_ARG_HANDLE_CHECKED(Object, object, 0); |
| 592 return *Object::TypeOf(isolate, object); |
| 593 } |
| 594 |
| 588 } // namespace internal | 595 } // namespace internal |
| 589 } // namespace v8 | 596 } // namespace v8 |
| OLD | NEW |