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

Unified Diff: tests/standalone/byte_array_test.dart

Issue 11794038: Bug fix and improvements to clamped arrays. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 11 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 | « runtime/vm/intrinsifier_x64.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/standalone/byte_array_test.dart
===================================================================
--- tests/standalone/byte_array_test.dart (revision 16756)
+++ tests/standalone/byte_array_test.dart (working copy)
@@ -48,6 +48,13 @@
byteArray[1] = 0;
Expect.equals(0, byteArray[1]);
+ for (int i = 0; i < byteArray.length; i++) {
+ byteArray[i] = i;
+ }
+ for (int i = 0; i < byteArray.length; i++) {
+ Expect.equals(i, byteArray[i]);
+ }
+
// These should eventually throw.
byteArray[1] = 256;
byteArray[1] = -1;
@@ -67,6 +74,12 @@
Expect.equals(255, byteArray[1]);
byteArray[1] = 0;
Expect.equals(0, byteArray[1]);
+ for (int i = 0; i < byteArray.length; i++) {
+ byteArray[i] = i;
+ }
+ for (int i = 0; i < byteArray.length; i++) {
+ Expect.equals(i, byteArray[i]);
+ }
// These should eventually throw.
byteArray[1] = 256;
« no previous file with comments | « runtime/vm/intrinsifier_x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698