OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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/debug/liveedit.h" | 5 #include "src/debug/liveedit.h" |
6 | 6 |
7 #include "src/ast/scopeinfo.h" | 7 #include "src/ast/scopeinfo.h" |
8 #include "src/ast/scopes.h" | 8 #include "src/ast/scopes.h" |
9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
10 #include "src/compilation-cache.h" | 10 #include "src/compilation-cache.h" |
(...skipping 1682 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1693 Handle<JSArray> result_; | 1693 Handle<JSArray> result_; |
1694 }; | 1694 }; |
1695 | 1695 |
1696 | 1696 |
1697 // Drops all call frame matched by target and all frames above them. | 1697 // Drops all call frame matched by target and all frames above them. |
1698 template <typename TARGET> | 1698 template <typename TARGET> |
1699 static const char* DropActivationsInActiveThreadImpl(Isolate* isolate, | 1699 static const char* DropActivationsInActiveThreadImpl(Isolate* isolate, |
1700 TARGET& target, // NOLINT | 1700 TARGET& target, // NOLINT |
1701 bool do_drop) { | 1701 bool do_drop) { |
1702 Debug* debug = isolate->debug(); | 1702 Debug* debug = isolate->debug(); |
1703 Zone zone; | 1703 Zone zone(isolate->allocator()); |
1704 Vector<StackFrame*> frames = CreateStackMap(isolate, &zone); | 1704 Vector<StackFrame*> frames = CreateStackMap(isolate, &zone); |
1705 | 1705 |
1706 | 1706 |
1707 int top_frame_index = -1; | 1707 int top_frame_index = -1; |
1708 int frame_index = 0; | 1708 int frame_index = 0; |
1709 for (; frame_index < frames.length(); frame_index++) { | 1709 for (; frame_index < frames.length(); frame_index++) { |
1710 StackFrame* frame = frames[frame_index]; | 1710 StackFrame* frame = frames[frame_index]; |
1711 if (frame->id() == debug->break_frame_id()) { | 1711 if (frame->id() == debug->break_frame_id()) { |
1712 top_frame_index = frame_index; | 1712 top_frame_index = frame_index; |
1713 break; | 1713 break; |
(...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2035 isolate_->active_function_info_listener()->FunctionCode(code); | 2035 isolate_->active_function_info_listener()->FunctionCode(code); |
2036 } | 2036 } |
2037 | 2037 |
2038 | 2038 |
2039 bool LiveEditFunctionTracker::IsActive(Isolate* isolate) { | 2039 bool LiveEditFunctionTracker::IsActive(Isolate* isolate) { |
2040 return isolate->active_function_info_listener() != NULL; | 2040 return isolate->active_function_info_listener() != NULL; |
2041 } | 2041 } |
2042 | 2042 |
2043 } // namespace internal | 2043 } // namespace internal |
2044 } // namespace v8 | 2044 } // namespace v8 |
OLD | NEW |