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

Unified Diff: tests/lib/math/min_max_test.dart

Issue 54723007: Fix warnings in library-tests. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments Created 7 years, 1 month 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 | « tests/lib/lib.status ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/lib/math/min_max_test.dart
diff --git a/tests/lib/math/min_max_test.dart b/tests/lib/math/min_max_test.dart
index 2b16176740f3449cacdc90bf5bef07aa2618403a..1f891853b0daf320781239e651717d03f690f832 100644
--- a/tests/lib/math/min_max_test.dart
+++ b/tests/lib/math/min_max_test.dart
@@ -15,12 +15,12 @@ var nan = double.NAN;
class Wrap implements Comparable {
final value;
Wrap(this.value);
- int compare(Wrap other) => value.compare(other.value);
- bool operator<(Wrap other) => compare(other) < 0;
- bool operator<=(Wrap other) => compare(other) <= 0;
- bool operator>(Wrap other) => compare(other) > 0;
- bool operator>=(Wrap other) => compare(other) >= 0;
- bool operator==(other) => other is Wrap && compare(other) == 0;
+ int compareTo(Wrap other) => value.compareTo(other.value);
+ bool operator<(Wrap other) => compareTo(other) < 0;
+ bool operator<=(Wrap other) => compareTo(other) <= 0;
+ bool operator>(Wrap other) => compareTo(other) > 0;
+ bool operator>=(Wrap other) => compareTo(other) >= 0;
+ bool operator==(other) => other is Wrap && compareTo(other) == 0;
String toString() => 'Wrap($value)';
int get hashCode => value.hashCode;
}
« no previous file with comments | « tests/lib/lib.status ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698