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

Unified Diff: pkg/compiler/lib/src/js_emitter/code_emitter_task.dart

Issue 2903753002: Use failedAt in more places (js_emitter) (Closed)
Patch Set: Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | pkg/compiler/lib/src/js_emitter/full_emitter/class_emitter.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_emitter/code_emitter_task.dart
diff --git a/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart b/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart
index a2b1d97274b3d6607dc38a4844faf0cdf03279d0..6c4cff7bf3a9694068be2c2cad01d6fdc63ed208 100644
--- a/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart
+++ b/pkg/compiler/lib/src/js_emitter/code_emitter_task.dart
@@ -67,14 +67,16 @@ class CodeEmitterTask extends CompilerTask {
}
NativeEmitter get nativeEmitter {
- assert(invariant(NO_LOCATION_SPANNABLE, _nativeEmitter != null,
- message: "NativeEmitter has not been created yet."));
+ assert(
+ _nativeEmitter != null,
+ failedAt(
+ NO_LOCATION_SPANNABLE, "NativeEmitter has not been created yet."));
return _nativeEmitter;
}
Emitter get emitter {
- assert(invariant(NO_LOCATION_SPANNABLE, _emitter != null,
- message: "Emitter has not been created yet."));
+ assert(_emitter != null,
+ failedAt(NO_LOCATION_SPANNABLE, "Emitter has not been created yet."));
return _emitter;
}
« no previous file with comments | « no previous file | pkg/compiler/lib/src/js_emitter/full_emitter/class_emitter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698