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

Unified Diff: dart/lib/compiler/implementation/util/util.dart

Issue 11308006: Throw an exception when invariant fails and report nice diagnostic. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 2 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
« no previous file with comments | « dart/lib/compiler/implementation/tree/nodes.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/lib/compiler/implementation/util/util.dart
diff --git a/dart/lib/compiler/implementation/util/util.dart b/dart/lib/compiler/implementation/util/util.dart
index ef3b0f63967d080d320c22d8fb7b1e38a6c5a660..b39bd461920b19bda11a3c59cc85923cc0dc0f8a 100644
--- a/dart/lib/compiler/implementation/util/util.dart
+++ b/dart/lib/compiler/implementation/util/util.dart
@@ -12,4 +12,13 @@ part 'link.dart';
* Tagging interface for classes from which source spans can be generated.
*/
// TODO(johnniwinther): Find a better name.
+// TODO(ahe): How about "Bolt"?
abstract class Spannable {}
+
+class SpannableAssertionFailure {
+ final Spannable node;
+ final String message;
+ SpannableAssertionFailure(this.node, this.message);
+
+ String toString() => 'compiler crashed.';
+}
« no previous file with comments | « dart/lib/compiler/implementation/tree/nodes.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698