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

Unified Diff: packages/quiver/lib/testing/src/runtime/checked_mode.dart

Issue 2989763002: Update charted to 0.4.8 and roll (Closed)
Patch Set: Removed Cutch from list of reviewers Created 3 years, 5 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: packages/quiver/lib/testing/src/runtime/checked_mode.dart
diff --git a/packages/quiver/lib/testing/src/runtime/checked_mode.dart b/packages/quiver/lib/testing/src/runtime/checked_mode.dart
index 05dfaaedac445403b631526fb4b730bbcbcc2ce4..63735f7e74cbbc4efc1f5886b6c091fb8f2be930 100644
--- a/packages/quiver/lib/testing/src/runtime/checked_mode.dart
+++ b/packages/quiver/lib/testing/src/runtime/checked_mode.dart
@@ -14,11 +14,9 @@
part of quiver.testing.runtime;
-/**
- * Asserts that the current runtime has checked mode enabled.
- *
- * Otherwise, throws [StateError].
- */
+/// Asserts that the current runtime has checked mode enabled.
+///
+/// Otherwise, throws [StateError].
void assertCheckedMode() {
if (_isCheckedMode == null) _isCheckedMode = _checkForCheckedMode();
@@ -33,10 +31,12 @@ bool _checkForCheckedMode() {
Object sentinal = new Object();
try {
var i = 1 as dynamic;
- String string = i;
+ _takeString(i);
throw sentinal;
} catch (e) {
if (e == sentinal) return false;
}
return true;
}
+
+void _takeString(String value) {}
« no previous file with comments | « packages/quiver/lib/testing/src/equality/equality.dart ('k') | packages/quiver/lib/testing/src/time/time.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698