| 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 "src/arguments.h" | 7 #include "src/arguments.h" |
| 8 #include "src/debug/debug-evaluate.h" | 8 #include "src/debug/debug-evaluate.h" |
| 9 #include "src/debug/debug-frames.h" | 9 #include "src/debug/debug-frames.h" |
| 10 #include "src/debug/debug-scopes.h" | 10 #include "src/debug/debug-scopes.h" |
| (...skipping 1697 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1708 isolate->debug()->PrepareStepInSuspendedGenerator(); | 1708 isolate->debug()->PrepareStepInSuspendedGenerator(); |
| 1709 return isolate->heap()->undefined_value(); | 1709 return isolate->heap()->undefined_value(); |
| 1710 } | 1710 } |
| 1711 | 1711 |
| 1712 RUNTIME_FUNCTION(Runtime_DebugPushPromise) { | 1712 RUNTIME_FUNCTION(Runtime_DebugPushPromise) { |
| 1713 DCHECK(args.length() == 2); | 1713 DCHECK(args.length() == 2); |
| 1714 HandleScope scope(isolate); | 1714 HandleScope scope(isolate); |
| 1715 CONVERT_ARG_HANDLE_CHECKED(JSObject, promise, 0); | 1715 CONVERT_ARG_HANDLE_CHECKED(JSObject, promise, 0); |
| 1716 CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 1); | 1716 CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 1); |
| 1717 isolate->PushPromise(promise, function); | 1717 isolate->PushPromise(promise, function); |
| 1718 // If we are in step-in mode, flood the handler. | |
| 1719 isolate->debug()->EnableStepIn(); | |
| 1720 return isolate->heap()->undefined_value(); | 1718 return isolate->heap()->undefined_value(); |
| 1721 } | 1719 } |
| 1722 | 1720 |
| 1723 | 1721 |
| 1724 RUNTIME_FUNCTION(Runtime_DebugPopPromise) { | 1722 RUNTIME_FUNCTION(Runtime_DebugPopPromise) { |
| 1725 DCHECK(args.length() == 0); | 1723 DCHECK(args.length() == 0); |
| 1726 SealHandleScope shs(isolate); | 1724 SealHandleScope shs(isolate); |
| 1727 isolate->PopPromise(); | 1725 isolate->PopPromise(); |
| 1728 return isolate->heap()->undefined_value(); | 1726 return isolate->heap()->undefined_value(); |
| 1729 } | 1727 } |
| (...skipping 13 matching lines...) Expand all Loading... |
| 1743 return Smi::FromInt(isolate->debug()->is_active()); | 1741 return Smi::FromInt(isolate->debug()->is_active()); |
| 1744 } | 1742 } |
| 1745 | 1743 |
| 1746 | 1744 |
| 1747 RUNTIME_FUNCTION(Runtime_DebugBreakInOptimizedCode) { | 1745 RUNTIME_FUNCTION(Runtime_DebugBreakInOptimizedCode) { |
| 1748 UNIMPLEMENTED(); | 1746 UNIMPLEMENTED(); |
| 1749 return NULL; | 1747 return NULL; |
| 1750 } | 1748 } |
| 1751 } // namespace internal | 1749 } // namespace internal |
| 1752 } // namespace v8 | 1750 } // namespace v8 |
| OLD | NEW |