OLD | NEW |
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 // Patch file for dart:developer library. | 5 // Patch file for dart:developer library. |
6 | 6 |
7 import 'dart:_js_helper' show patch; | 7 import 'dart:_js_helper' show patch, ForceInline; |
8 import 'dart:_foreign_helper' show JS; | 8 import 'dart:_foreign_helper' show JS; |
9 | 9 |
10 @patch | 10 @patch |
11 @ForceInline() | 11 @ForceInline() |
12 bool debugger({bool when: true, String message}) { | 12 bool debugger({bool when: true, String message}) { |
13 if (when) { | 13 if (when) { |
14 JS('', 'debugger'); | 14 JS('', 'debugger'); |
15 } | 15 } |
16 return when; | 16 return when; |
17 } | 17 } |
(...skipping 19 matching lines...) Expand all Loading... |
37 | 37 |
38 @patch | 38 @patch |
39 ServiceExtensionHandler _lookupExtension(String method) { | 39 ServiceExtensionHandler _lookupExtension(String method) { |
40 return _extensions[method]; | 40 return _extensions[method]; |
41 } | 41 } |
42 | 42 |
43 @patch | 43 @patch |
44 _registerExtension(String method, ServiceExtensionHandler handler) { | 44 _registerExtension(String method, ServiceExtensionHandler handler) { |
45 _extensions[method] = handler; | 45 _extensions[method] = handler; |
46 } | 46 } |
OLD | NEW |