Index: tests/language/regex/range-bound-ffff_test.dart |
diff --git a/tests/language/regex/range-bound-ffff_test.dart b/tests/language/regex/range-bound-ffff_test.dart |
new file mode 100644 |
index 0000000000000000000000000000000000000000..a1e11a74574cd8c0d2b6a72600f1508f74fd9ec7 |
--- /dev/null |
+++ b/tests/language/regex/range-bound-ffff_test.dart |
@@ -0,0 +1,14 @@ |
+// Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
+// for details. All rights reserved. Use of this source code is governed by a |
+// BSD-style license that can be found in the LICENSE file. |
+ |
+import 'util.dart'; |
+import 'package:expect/expect.dart'; |
+ |
+void main() { |
+ description( |
+ 'Test for rdar:/68455379, a case-insensitive regex containing a character class containing a range with an upper bound of \uFFFF can lead to an infinite-loop.' |
+ ); |
+ |
+ shouldBe(firstMatch("A", new RegExp(r"[\u0001-\uFFFF]", caseSensitive: false)), ["A"]); |
+} |