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

Side by Side Diff: runtime/vm/dart_api_impl.cc

Issue 8687037: Very first steps for a debugger (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 years 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "include/dart_api.h" 5 #include "include/dart_api.h"
6 6
7 #include "vm/bigint_operations.h" 7 #include "vm/bigint_operations.h"
8 #include "vm/class_finalizer.h" 8 #include "vm/class_finalizer.h"
9 #include "vm/compiler.h" 9 #include "vm/compiler.h"
10 #include "vm/dart.h" 10 #include "vm/dart.h"
11 #include "vm/dart_api_impl.h" 11 #include "vm/dart_api_impl.h"
12 #include "vm/dart_api_state.h" 12 #include "vm/dart_api_state.h"
13 #include "vm/dart_entry.h" 13 #include "vm/dart_entry.h"
14 #include "vm/debugger.h"
14 #include "vm/debuginfo.h" 15 #include "vm/debuginfo.h"
15 #include "vm/exceptions.h" 16 #include "vm/exceptions.h"
16 #include "vm/growable_array.h" 17 #include "vm/growable_array.h"
17 #include "vm/longjump.h" 18 #include "vm/longjump.h"
18 #include "vm/native_entry.h" 19 #include "vm/native_entry.h"
19 #include "vm/object.h" 20 #include "vm/object.h"
20 #include "vm/object_store.h" 21 #include "vm/object_store.h"
21 #include "vm/port.h" 22 #include "vm/port.h"
22 #include "vm/resolver.h" 23 #include "vm/resolver.h"
23 #include "vm/snapshot.h" 24 #include "vm/snapshot.h"
(...skipping 1532 matching lines...) Expand 10 before | Expand all | Expand 10 after
1556 // which shows up because of the use of setjmp. 1557 // which shows up because of the use of setjmp.
1557 static void InvokeStatic(Isolate* isolate, 1558 static void InvokeStatic(Isolate* isolate,
1558 const Function& function, 1559 const Function& function,
1559 GrowableArray<const Object*>& args, 1560 GrowableArray<const Object*>& args,
1560 Dart_Handle* result) { 1561 Dart_Handle* result) {
1561 ASSERT(isolate != NULL); 1562 ASSERT(isolate != NULL);
1562 LongJump* base = isolate->long_jump_base(); 1563 LongJump* base = isolate->long_jump_base();
1563 LongJump jump; 1564 LongJump jump;
1564 isolate->set_long_jump_base(&jump); 1565 isolate->set_long_jump_base(&jump);
1565 if (setjmp(*jump.Set()) == 0) { 1566 if (setjmp(*jump.Set()) == 0) {
1567 isolate->debugger()->Initialize(isolate);
siva 2011/11/30 00:00:47 Why do we have to wait until InvokeStatic is calle
hausner 2011/11/30 01:17:05 Because I need to wait until all the code is loade
1566 const Array& kNoArgumentNames = Array::Handle(); 1568 const Array& kNoArgumentNames = Array::Handle();
1567 const Instance& retval = Instance::Handle( 1569 const Instance& retval = Instance::Handle(
1568 DartEntry::InvokeStatic(function, args, kNoArgumentNames)); 1570 DartEntry::InvokeStatic(function, args, kNoArgumentNames));
1569 if (retval.IsUnhandledException()) { 1571 if (retval.IsUnhandledException()) {
1570 *result = Api::ErrorFromException(retval); 1572 *result = Api::ErrorFromException(retval);
1571 } else { 1573 } else {
1572 *result = Api::NewLocalHandle(retval); 1574 *result = Api::NewLocalHandle(retval);
1573 } 1575 }
1574 } else { 1576 } else {
1575 SetupErrorResult(result); 1577 SetupErrorResult(result);
(...skipping 721 matching lines...) Expand 10 before | Expand all | Expand 10 after
2297 } 2299 }
2298 delete debug_region; 2300 delete debug_region;
2299 } else { 2301 } else {
2300 *buffer = NULL; 2302 *buffer = NULL;
2301 *buffer_size = 0; 2303 *buffer_size = 0;
2302 } 2304 }
2303 } 2305 }
2304 2306
2305 2307
2306 } // namespace dart 2308 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698