| 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/arguments.h" | 5 #include "src/arguments.h" |
| 6 #include "src/isolate-inl.h" | 6 #include "src/isolate-inl.h" |
| 7 #include "src/runtime/runtime-utils.h" | 7 #include "src/runtime/runtime-utils.h" |
| 8 | 8 |
| 9 namespace v8 { | 9 namespace v8 { |
| 10 namespace internal { | 10 namespace internal { |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 177 RUNTIME_FUNCTION(Runtime_GreaterThanOrEqual) { | 177 RUNTIME_FUNCTION(Runtime_GreaterThanOrEqual) { |
| 178 HandleScope scope(isolate); | 178 HandleScope scope(isolate); |
| 179 DCHECK_EQ(2, args.length()); | 179 DCHECK_EQ(2, args.length()); |
| 180 CONVERT_ARG_HANDLE_CHECKED(Object, x, 0); | 180 CONVERT_ARG_HANDLE_CHECKED(Object, x, 0); |
| 181 CONVERT_ARG_HANDLE_CHECKED(Object, y, 1); | 181 CONVERT_ARG_HANDLE_CHECKED(Object, y, 1); |
| 182 Maybe<bool> result = Object::GreaterThanOrEqual(x, y); | 182 Maybe<bool> result = Object::GreaterThanOrEqual(x, y); |
| 183 if (!result.IsJust()) return isolate->heap()->exception(); | 183 if (!result.IsJust()) return isolate->heap()->exception(); |
| 184 return isolate->heap()->ToBoolean(result.FromJust()); | 184 return isolate->heap()->ToBoolean(result.FromJust()); |
| 185 } | 185 } |
| 186 | 186 |
| 187 RUNTIME_FUNCTION(Runtime_InstanceOf) { | |
| 188 HandleScope shs(isolate); | |
| 189 DCHECK_EQ(2, args.length()); | |
| 190 CONVERT_ARG_HANDLE_CHECKED(Object, object, 0); | |
| 191 CONVERT_ARG_HANDLE_CHECKED(Object, callable, 1); | |
| 192 RETURN_RESULT_OR_FAILURE(isolate, | |
| 193 Object::InstanceOf(isolate, object, callable)); | |
| 194 } | |
| 195 | |
| 196 } // namespace internal | 187 } // namespace internal |
| 197 } // namespace v8 | 188 } // namespace v8 |
| OLD | NEW |