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

Unified Diff: tests/corelib/compare_to2_test.dart

Issue 12317107: ceil/floor/truncate/round return integers. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Reupload due to error3 Created 7 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
« no previous file with comments | « tests/co19/co19-runtime.status ('k') | tests/corelib/double_ceil2_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/corelib/compare_to2_test.dart
diff --git a/tests/corelib/compare_to2_test.dart b/tests/corelib/compare_to2_test.dart
index 8100fc46b61c5f9f7200e7415a00c9129c957103..3d1353c2957bbca9715794e3c3d83cbb8c62be22 100644
--- a/tests/corelib/compare_to2_test.dart
+++ b/tests/corelib/compare_to2_test.dart
@@ -13,14 +13,14 @@ main() {
var maxFraction = 0.9999999999999999;
var minAbove1 = 1.0000000000000002;
var maxNonInt = 4503599627370495.5;
- var maxNonIntFloorAsDouble = maxNonInt.floor();
- var maxNonIntFloorAsInt = maxNonIntFloorAsDouble.toInt();
+ var maxNonIntFloorAsInt = maxNonInt.floor();
+ var maxNonIntFloorAsDouble = maxNonIntFloorAsInt.toDouble();
var maxExactIntAsDouble = 9007199254740992.0;
var maxExactIntAsInt = 9007199254740992;
var two53 = 1 << 53; // Same as maxExactIntAsInt.
var two53p1 = two53 + 1;
var maxFiniteAsDouble = 1.7976931348623157e+308;
- var maxFiniteAsInt = maxFiniteAsDouble.toInt();
+ var maxFiniteAsInt = maxFiniteAsDouble.truncate();
int huge = 1 << 2000;
int hugeP1 = huge + 1;
var inf = double.INFINITY;
« no previous file with comments | « tests/co19/co19-runtime.status ('k') | tests/corelib/double_ceil2_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698