Index: test/mjsunit/string-slices.js |
diff --git a/test/mjsunit/string-slices.js b/test/mjsunit/string-slices.js |
index 5b1dc360ab3c24a0c3569116a01a15ea96e00eba..2fec04b0b084a3a4605f982c8ab391ed22c76a70 100755 |
--- a/test/mjsunit/string-slices.js |
+++ b/test/mjsunit/string-slices.js |
@@ -222,4 +222,15 @@ function test_crankshaft() { |
test_crankshaft(); |
%OptimizeFunctionOnNextCall(test_crankshaft); |
-test_crankshaft(); |
+test_crankshaft(); |
+ |
+var s1 = "12345678901234567890"; |
+var s2 = "abcdefghijklmnopqrstuvwxyz"; |
+var c1 = s1 + s2; |
+var c2 = s1 + c1 + s2; |
+assertEquals("234567890123456789", c1.substring(1, 19)); |
+assertEquals("bcdefghijklmno", c1.substring(21, 35)); |
+assertEquals("2345678901234567890abcdefghijklmno", c1.substring(1, 35)); |
+assertEquals("234567890123456789", c2.substring(1, 19)); |
+assertEquals("bcdefghijklmno", c2.substring(41, 55)); |
+assertEquals("2345678901234567890abcdefghijklmno", c2.substring(21, 55)); |