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

Side by Side Diff: sdk/lib/developer/extension.dart

Issue 1971193002: Patches to support Dart VM patch files in dart2js. (Closed) Base URL: sso://user/ahe/dart-sdk@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
« no previous file with comments | « sdk/lib/core/object.dart ('k') | sdk/lib/developer/profiler.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 part of dart.developer; 5 part of dart.developer;
6 6
7 /// A response to a service protocol extension RPC. 7 /// A response to a service protocol extension RPC.
8 /// 8 ///
9 /// If the RPC was successful, use [ServiceExtensionResponse.result], otherwise 9 /// If the RPC was successful, use [ServiceExtensionResponse.result], otherwise
10 /// use [ServiceExtensionResponse.error]. 10 /// use [ServiceExtensionResponse.error].
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 } 159 }
160 if (eventData is! Map) { 160 if (eventData is! Map) {
161 throw new ArgumentError.value(eventData, 161 throw new ArgumentError.value(eventData,
162 'eventData', 162 'eventData',
163 'Must be a Map'); 163 'Must be a Map');
164 } 164 }
165 String eventDataAsString = JSON.encode(eventData); 165 String eventDataAsString = JSON.encode(eventData);
166 _postEvent(eventKind, eventDataAsString); 166 _postEvent(eventKind, eventDataAsString);
167 } 167 }
168 168
169 external _postEvent(String eventKind, String eventData); 169 external void _postEvent(String eventKind, String eventData);
170 170
171 // Both of these functions are written inside C++ to avoid updating the data 171 // Both of these functions are written inside C++ to avoid updating the data
172 // structures in Dart, getting an OOB, and observing stale state. Do not move 172 // structures in Dart, getting an OOB, and observing stale state. Do not move
173 // these into Dart code unless you can ensure that the operations will can be 173 // these into Dart code unless you can ensure that the operations will can be
174 // done atomically. Native code lives in vm/isolate.cc- 174 // done atomically. Native code lives in vm/isolate.cc-
175 // LookupServiceExtensionHandler and RegisterServiceExtensionHandler. 175 // LookupServiceExtensionHandler and RegisterServiceExtensionHandler.
176 external ServiceExtensionHandler _lookupExtension(String method); 176 external ServiceExtensionHandler _lookupExtension(String method);
177 external _registerExtension(String method, ServiceExtensionHandler handler); 177 external _registerExtension(String method, ServiceExtensionHandler handler);
OLDNEW
« no previous file with comments | « sdk/lib/core/object.dart ('k') | sdk/lib/developer/profiler.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698