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

Side by Side Diff: sdk/lib/_internal/compiler/js_lib/debugger_patch.dart

Issue 1121293003: Provide a dart2js implementation of dart:debugger (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Review fixes Created 5 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | sdk/lib/_internal/libraries.dart » ('j') | sdk/lib/debugger/debugger.dart » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // BSD-style license that can be found in the LICENSE file.
4
5 // Patch file for dart:debugger library.
6
7 import 'dart:_js_helper' show patch;
8 import 'dart:_foreign_helper' show JS;
9
10 @patch class Debugger {
11 /// Stop the program as if a breakpoint where hit at the following statement.
12 /// NOTE: When invoked, the isolate will not return until a debugger
13 /// continues execution. When running in the Dart VM the behaviour is the same
14 /// regardless of whether or not a debugger is connected. When compiled to
15 /// JavaScript, this uses the "debugger" statement, and behaves exactly as
16 /// that does.
17 @patch
18 @ForceInline()
19 static void breakHere() {
20 JS('', 'debugger');
21 }
22
23 /// If [expr] is true, stop the program as if a breakpoint where hit at the
24 /// following statement. See [breakHere].
25 @patch
26 @ForceInline()
27 static void breakHereIf(bool expr) {
28 if (expr) {
29 breakHere();
30 }
31 }
32 }
OLDNEW
« no previous file with comments | « no previous file | sdk/lib/_internal/libraries.dart » ('j') | sdk/lib/debugger/debugger.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698