| 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/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #include "src/arguments.h" | 7 #include "src/arguments.h" |
| 8 #include "src/debug.h" | 8 #include "src/debug.h" |
| 9 #include "src/runtime/runtime-utils.h" | 9 #include "src/runtime/runtime-utils.h" |
| 10 | 10 |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 51 isolate->RunMicrotasks(); | 51 isolate->RunMicrotasks(); |
| 52 return isolate->heap()->undefined_value(); | 52 return isolate->heap()->undefined_value(); |
| 53 } | 53 } |
| 54 | 54 |
| 55 | 55 |
| 56 RUNTIME_FUNCTION(Runtime_DeliverObservationChangeRecords) { | 56 RUNTIME_FUNCTION(Runtime_DeliverObservationChangeRecords) { |
| 57 HandleScope scope(isolate); | 57 HandleScope scope(isolate); |
| 58 DCHECK(args.length() == 2); | 58 DCHECK(args.length() == 2); |
| 59 CONVERT_ARG_HANDLE_CHECKED(JSFunction, callback, 0); | 59 CONVERT_ARG_HANDLE_CHECKED(JSFunction, callback, 0); |
| 60 CONVERT_ARG_HANDLE_CHECKED(Object, argument, 1); | 60 CONVERT_ARG_HANDLE_CHECKED(Object, argument, 1); |
| 61 v8::TryCatch catcher; | 61 v8::TryCatch catcher(reinterpret_cast<v8::Isolate*>(isolate)); |
| 62 // We should send a message on uncaught exception thrown during | 62 // We should send a message on uncaught exception thrown during |
| 63 // Object.observe delivery while not interrupting further delivery, thus | 63 // Object.observe delivery while not interrupting further delivery, thus |
| 64 // we make a call inside a verbose TryCatch. | 64 // we make a call inside a verbose TryCatch. |
| 65 catcher.SetVerbose(true); | 65 catcher.SetVerbose(true); |
| 66 Handle<Object> argv[] = {argument}; | 66 Handle<Object> argv[] = {argument}; |
| 67 | 67 |
| 68 // Allow stepping into the observer callback. | 68 // Allow stepping into the observer callback. |
| 69 Debug* debug = isolate->debug(); | 69 Debug* debug = isolate->debug(); |
| 70 if (debug->is_active() && debug->IsStepping() && | 70 if (debug->is_active() && debug->IsStepping() && |
| 71 debug->last_step_action() == StepIn) { | 71 debug->last_step_action() == StepIn) { |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 RUNTIME_FUNCTION(Runtime_GetObjectContextNotifierPerformChange) { | 152 RUNTIME_FUNCTION(Runtime_GetObjectContextNotifierPerformChange) { |
| 153 HandleScope scope(isolate); | 153 HandleScope scope(isolate); |
| 154 DCHECK(args.length() == 1); | 154 DCHECK(args.length() == 1); |
| 155 CONVERT_ARG_HANDLE_CHECKED(JSObject, object_info, 0); | 155 CONVERT_ARG_HANDLE_CHECKED(JSObject, object_info, 0); |
| 156 | 156 |
| 157 Handle<Context> context(object_info->GetCreationContext(), isolate); | 157 Handle<Context> context(object_info->GetCreationContext(), isolate); |
| 158 return context->native_object_notifier_perform_change(); | 158 return context->native_object_notifier_perform_change(); |
| 159 } | 159 } |
| 160 } // namespace internal | 160 } // namespace internal |
| 161 } // namespace v8 | 161 } // namespace v8 |
| OLD | NEW |