@@ -41,26 +41,26 @@ let tests =
41
41
let options = RegexOptions.NonBacktracking
42
42
int options |> equal 1024
43
43
44
- testCase " Nonbacktracking regex tests" <| fun _ ->
45
- // Note: this is not consistent with .NET because JS linear engine
46
- // does not support unicode. JS \d = 10 digits, .NET \d = 350+ digits
47
- // but for these tests the behavior should be identical.
48
- let none = RegexOptions.None
49
- let nonb = RegexOptions.NonBacktracking
50
- let multiline = RegexOptions.Multiline
51
- let ignorecase = RegexOptions.IgnoreCase
52
- let multilineignorecase = multiline ||| ignorecase
53
- let str = " For more information, see Chapter 3.4.5.1"
54
- let sameResult extraopts str pat =
55
- let result1 = Regex.Match( str, pat, none ||| extraopts) .Success
56
- let result2 = Regex.Match( str, pat, nonb ||| extraopts) .Success
57
- equal result1 result2
58
- sameResult none str " Chapter \d +(\.\d )*"
59
- sameResult none str " chapter \d +(\.\d )*"
60
- sameResult multilineignorecase " ^ab" " ab\n cd"
61
- sameResult multilineignorecase " ^cd" " ab\n cd"
62
- sameResult multilineignorecase " ^AB" " ab\n cd"
63
- sameResult multilineignorecase " ^bc" " ab\n cd"
44
+ // these tests depend on '--enable-experimental-regexp-engine' or
45
+ // an newer version of V8 that supports 'l' flag
46
+ // the tests are ascii only, 'l' and 'u' together are not supported
47
+ // testCase "Nonbacktracking regex tests" <| fun _ ->
48
+ // let none = RegexOptions.None
49
+ // let nonb = RegexOptions.NonBacktracking
50
+ // let multiline = RegexOptions.Multiline
51
+ // let ignorecase = RegexOptions.IgnoreCase
52
+ // let multilineignorecase = multiline ||| ignorecase
53
+ // let str = "For more information, see Chapter 3.4.5.1"
54
+ // let sameResult extraopts str pat =
55
+ // let result1 = Regex.Match(str, pat, none ||| extraopts).Success
56
+ // let result2 = Regex.Match(str, pat, nonb ||| extraopts).Success
57
+ // equal result1 result2
58
+ // sameResult none str "Chapter \d+(\.\d)*"
59
+ // sameResult none str "chapter \d+(\.\d)*"
60
+ // sameResult multilineignorecase "^ab" "ab\ncd"
61
+ // sameResult multilineignorecase "^cd" "ab\ncd"
62
+ // sameResult multilineignorecase "^AB" "ab\ncd"
63
+ // sameResult multilineignorecase "^bc" "ab\ncd"
64
64
65
65
66
66
testCase " Regex.IsMatch with IgnoreCase and Multiline works" <| fun _ ->
0 commit comments