Index: tests/language/optimized_string_charcodeat_test.dart |
diff --git a/tests/language/optimized_string_charcodeat_test.dart b/tests/language/optimized_string_charcodeat_test.dart |
index 1493db6ae8e184faf02a283e74a174c0d34f1ca6..149069cd085102651b84e7175bfeae464ecde1f2 100644 |
--- a/tests/language/optimized_string_charcodeat_test.dart |
+++ b/tests/language/optimized_string_charcodeat_test.dart |
@@ -7,7 +7,6 @@ |
import "package:expect/expect.dart"; |
- |
String one_byte = "hest"; |
String two_byte = "h\u{2029}ns"; |
@@ -15,38 +14,38 @@ int testOneByteCodeUnitAt(String x, int j) { |
int test() { |
return x.codeUnitAt(j); |
} |
+ |
for (int i = 0; i < 20; i++) test(); |
return test(); |
} |
- |
int testTwoByteCodeUnitAt(String x, int j) { |
int test() { |
return x.codeUnitAt(j); |
} |
+ |
for (int i = 0; i < 20; i++) test(); |
return test(); |
} |
- |
int testConstantStringCodeUnitAt(int j) { |
int test() { |
return "høns".codeUnitAt(j); |
} |
+ |
for (int i = 0; i < 20; i++) test(); |
return test(); |
} |
- |
int testConstantIndexCodeUnitAt(String x) { |
int test() { |
return x.codeUnitAt(1); |
} |
+ |
for (int i = 0; i < 20; i++) test(); |
return test(); |
} |
- |
int testOneByteCodeUnitAtInLoop(var x) { |
var result = 0; |
for (int i = 0; i < x.length; i++) { |
@@ -55,7 +54,6 @@ int testOneByteCodeUnitAtInLoop(var x) { |
return result; |
} |
- |
int testTwoByteCodeUnitAtInLoop(var x) { |
var result = 0; |
for (int i = 0; i < x.length; i++) { |
@@ -64,7 +62,6 @@ int testTwoByteCodeUnitAtInLoop(var x) { |
return result; |
} |
- |
main() { |
for (int j = 0; j < 10; j++) { |
Expect.equals(101, testOneByteCodeUnitAt(one_byte, 1)); |