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

Side by Side Diff: runtime/vm/bigint_operations_test.cc

Issue 9863023: Remove redundant assert. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "platform/assert.h" 5 #include "platform/assert.h"
6 #include "vm/bigint_operations.h" 6 #include "vm/bigint_operations.h"
7 #include "vm/object.h" 7 #include "vm/object.h"
8 #include "vm/object_store.h" 8 #include "vm/object_store.h"
9 #include "vm/unit_test.h" 9 #include "vm/unit_test.h"
10 10
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 bigint = BigintOperations::NewFromCString("123456"); 146 bigint = BigintOperations::NewFromCString("123456");
147 dbl = BigintOperations::ToDouble(bigint); 147 dbl = BigintOperations::ToDouble(bigint);
148 EXPECT_EQ(123456.0, dbl.value()); 148 EXPECT_EQ(123456.0, dbl.value());
149 149
150 bigint = BigintOperations::NewFromCString("123456789"); 150 bigint = BigintOperations::NewFromCString("123456789");
151 dbl = BigintOperations::ToDouble(bigint); 151 dbl = BigintOperations::ToDouble(bigint);
152 EXPECT_EQ(123456789.0, dbl.value()); 152 EXPECT_EQ(123456789.0, dbl.value());
153 153
154 bigint = BigintOperations::NewFromCString("12345678901234567"); 154 bigint = BigintOperations::NewFromCString("12345678901234567");
155 dbl = BigintOperations::ToDouble(bigint); 155 dbl = BigintOperations::ToDouble(bigint);
156 EXPECT_EQ(12345678901234567.0, dbl.value());
157 EXPECT_EQ(12345678901234568.0, dbl.value()); 156 EXPECT_EQ(12345678901234568.0, dbl.value());
158 157
159 bigint = BigintOperations::NewFromCString("98765432109876"); 158 bigint = BigintOperations::NewFromCString("98765432109876");
160 dbl = BigintOperations::ToDouble(bigint); 159 dbl = BigintOperations::ToDouble(bigint);
161 EXPECT_EQ(9.8765432109876e+13, dbl.value()); 160 EXPECT_EQ(9.8765432109876e+13, dbl.value());
162 161
163 bigint = BigintOperations::NewFromCString("0x17777777777778"); 162 bigint = BigintOperations::NewFromCString("0x17777777777778");
164 dbl = BigintOperations::ToDouble(bigint); 163 dbl = BigintOperations::ToDouble(bigint);
165 EXPECT_EQ(6605279453476728.0, dbl.value()); 164 EXPECT_EQ(6605279453476728.0, dbl.value());
166 165
(...skipping 2059 matching lines...) Expand 10 before | Expand all | Expand 10 after
2226 "123456789012345678901234567890123456789012345678901234567890123456789012" 2225 "123456789012345678901234567890123456789012345678901234567890123456789012"
2227 "345678901234567890123456789012345678901234567890123456789012345678901234" 2226 "345678901234567890123456789012345678901234567890123456789012345678901234"
2228 "567890123456789012345678901234567890123456789012345678901234567890123456" 2227 "567890123456789012345678901234567890123456789012345678901234567890123456"
2229 "789012345678901234567890123456789012345678901234567890123456789012345678" 2228 "789012345678901234567890123456789012345678901234567890123456789012345678"
2230 "90123456789012345678901234567890", 2229 "90123456789012345678901234567890",
2231 "0x1234567890ABCDEF01234567890ABCDEF01234567890ABCDEF01234567890ABCDEF" 2230 "0x1234567890ABCDEF01234567890ABCDEF01234567890ABCDEF01234567890ABCDEF"
2232 "01234567890ABCDEE"); 2231 "01234567890ABCDEE");
2233 } 2232 }
2234 2233
2235 } // namespace dart 2234 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698