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

Unified Diff: test/mjsunit/string-natives.js

Issue 71163006: Merge bleeding_edge r17376:17693. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/parser
Patch Set: Fix all.gyp 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 | « test/mjsunit/sin-cos.js ('k') | test/mozilla/mozilla.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/string-natives.js
diff --git a/test/mjsunit/string-natives.js b/test/mjsunit/string-natives.js
index b1ec875420cc094b2ede2310b1bcfd4ea4533648..cd1cde1fd79c5d60a829acb5ea1e3ff8d48234f5 100644
--- a/test/mjsunit/string-natives.js
+++ b/test/mjsunit/string-natives.js
@@ -29,15 +29,23 @@
function test() {
var s1 = %NewString(26, true);
+ for (i = 0; i < 26; i++) %_OneByteSeqStringSetChar(s1, i, 65);
+ assertEquals("AAAAAAAAAAAAAAAAAAAAAAAAAA", s1);
+ %_OneByteSeqStringSetChar(s1, 25, 66);
+ assertEquals("AAAAAAAAAAAAAAAAAAAAAAAAAB", s1);
for (i = 0; i < 26; i++) %_OneByteSeqStringSetChar(s1, i, i+65);
assertEquals("ABCDEFGHIJKLMNOPQRSTUVWXYZ", s1);
s1 = %TruncateString(s1, 13);
assertEquals("ABCDEFGHIJKLM", s1);
var s2 = %NewString(26, false);
+ for (i = 0; i < 26; i++) %_TwoByteSeqStringSetChar(s2, i, 65);
+ assertEquals("AAAAAAAAAAAAAAAAAAAAAAAAAA", s2);
+ %_TwoByteSeqStringSetChar(s2, 25, 66);
+ assertEquals("AAAAAAAAAAAAAAAAAAAAAAAAAB", s2);
for (i = 0; i < 26; i++) %_TwoByteSeqStringSetChar(s2, i, i+65);
assertEquals("ABCDEFGHIJKLMNOPQRSTUVWXYZ", s2);
- s2 = %TruncateString(s1, 13);
+ s2 = %TruncateString(s2, 13);
assertEquals("ABCDEFGHIJKLM", s2);
var s3 = %NewString(26, false);
« no previous file with comments | « test/mjsunit/sin-cos.js ('k') | test/mozilla/mozilla.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698