Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(140)

Unified Diff: vm/exceptions.cc

Issue 10173008: Simplify representation of stack frames. Remove the special types DartFrame/StubFrame and instead u… (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « vm/debugger.cc ('k') | vm/flow_graph_compiler_x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: vm/exceptions.cc
===================================================================
--- vm/exceptions.cc (revision 6919)
+++ vm/exceptions.cc (working copy)
@@ -28,8 +28,7 @@
while (!frame->IsEntryFrame()) {
if (frame->IsDartFrame()) {
stack_frame_pcs->Add(frame->pc());
- DartFrame* dart_frame = reinterpret_cast<DartFrame*>(frame);
- if (dart_frame->FindExceptionHandler(handler_pc)) {
+ if (frame->FindExceptionHandler(handler_pc)) {
*handler_sp = frame->sp();
*handler_fp = frame->fp();
return true;
@@ -123,8 +122,8 @@
// Return the script of the Dart function that called the native entry or the
// runtime entry. The frame iterator points to the callee.
RawScript* Exceptions::GetCallerScript(DartFrameIterator* iterator) {
- DartFrame* caller_frame = iterator->NextFrame();
- ASSERT(caller_frame != NULL);
+ StackFrame* caller_frame = iterator->NextFrame();
+ ASSERT(caller_frame != NULL && caller_frame->IsDartFrame());
const Function& caller = Function::Handle(caller_frame->LookupDartFunction());
ASSERT(!caller.IsNull());
const Class& caller_class = Class::Handle(caller.owner());
« no previous file with comments | « vm/debugger.cc ('k') | vm/flow_graph_compiler_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698