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

Unified Diff: sdk/lib/_internal/compiler/implementation/helpers/helpers.dart

Issue 208423012: Add helpers library to dart2js. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 9 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
Index: sdk/lib/_internal/compiler/implementation/helpers/helpers.dart
diff --git a/sdk/lib/_internal/compiler/implementation/helpers/helpers.dart b/sdk/lib/_internal/compiler/implementation/helpers/helpers.dart
new file mode 100644
index 0000000000000000000000000000000000000000..a12663029d79409368dbef0a360c70b84464b277
--- /dev/null
+++ b/sdk/lib/_internal/compiler/implementation/helpers/helpers.dart
@@ -0,0 +1,26 @@
+// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+/// Library for debugging helpers. The unittest analyze_unused_test checks that
+/// the helper are not used in production code.
+
+library dart2js.helpers;
+
+import "dart:collection";
+import '../dart2jslib.dart';
+import '../util/util.dart';
+
+part 'debug_collection.dart';
+part 'trace.dart';
+part 'expensive_map.dart';
+part 'expensive_set.dart';
+
+/// Print [s].
+debugPrint(s) => print(s);
+
+/// Print a message with a source location.
+reportHere(Compiler compiler, Spannable node, String debugMessage) {
+ compiler.reportInfo(node,
+ MessageKind.GENERIC, {'text': 'HERE: $debugMessage'});
+}

Powered by Google App Engine
This is Rietveld 408576698