You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let inline(|Like|_|)format = FSharpPlus.Parsing.trySscanf format
106
-
match"(%hello)"with Like "(%%%s)""hello"->()|_-> failwith "didn't match"
107
+
match"ab"with Like "%c"_-> failwith "wrong match"| Like "%c%c"('a','b')->()|_-> failwith "didn't match"
108
+
match"abc"with Like "%c%c"('a','b')-> failwith "wrong match"| Like "%c%c%c%s"('a','b','c',"")->()|_-> failwith "didn't match"
109
+
match"(%hello)"with
110
+
| Like "%d"_| Like "%f"_| Like "%x"_-> failwith "wrong match"
111
+
| Like "%%(%%%s)"_| Like "(%%%sa"_| Like "(%%hel%c"_| Like "%%h%cllo)"_-> failwith "wrong match"
112
+
| Like "(%%%s)""hello"->()
113
+
|_-> failwith "didn't match"
107
114
match"test--this-gg"with Like "%s--%s-%s"("test","this","gg")->()|_-> failwith "didn't match"
108
115
match"1 2.1 3.4 .3 43.2e32 0 f f"with Like "%f%F%g%G%e%E%c%c"(1f,2.1,3.4,0.3,43.2e32,0.,'f','f')->()|_-> failwith "didn't match"
109
116
match"1 2.1 3.4 .3 43.2e32 0 f f f"with Like "%f%F%g%G%e%E%c%c%c"(1f,2.1,3.4,0.3,43.2e32,0.,'f','f','f')->()|_-> failwith "didn't match"
110
-
match"1 2.1 3.4 .3 43.2e32 0 f f ff"with Like "%f%F%g%G%e%E%c%c%c%c"(1f,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f')->()|_-> failwith "didn't match"
111
-
match"1 2.1 3.4 .3 43.2e32 0 f f fff"with Like "%f%F%g%G%e%E%c%c%c%c%c"(1f,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f','f')->()|_-> failwith "didn't match"
112
-
match"1 2.1 3.4 .3 43.2e32 0 f f fff 16"with Like "%f%F%g%G%e%E%c%c%c%c%c%i"(1f,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f','f',16)->()|_-> failwith "didn't match"
113
-
match"1 2.1 3.4 .3 43.2e32 0 f f fff 16 17"with Like "%f%F%g%G%e%E%c%c%c%c%c%i%f"(1f,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f','f',16,17.)->()|_-> failwith "didn't match"
117
+
match"1 2.1 3.4 .3 43.2e32 0 f f ff"with Like "%B%F%g%G%e%E%c%c%c%c"(1,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f')->()|_-> failwith "didn't match"
118
+
match"1 2.1 3.4 .3 43.2e32 0 f f fff"with Like "%o%F%g%G%e%E%c%c%c%c%c"(1,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f','f')->()|_-> failwith "didn't match"
119
+
match"1 2.1 3.4 .3 43.2e32 0 f f fff16"with Like "%x%F%g%G%e%E%c%c%c%c%c%i"(1,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f','f',16)->()|_-> failwith "didn't match"
120
+
match"1 2.1 3.4 .3 43.2e32 0 f f fff16 17"with Like "%X%F%g%G%e%E%c%c%c%c%c%i%f"(1,2.1,3.4,0.3,43.2e32,0.,'f','f','f','f','f',16,17.)->()|_-> failwith "didn't match"
114
121
match"13 43 AA 77A"with Like "%x%X%x%o%X"(0x13,0x43,0xAA,0o77,0xA)->()|_-> failwith "didn't match"
115
122
match"13 43 AA 77A"with Like "%B%x%X%x%o%X"(0b1,0x3,0x43,0xAA,0o77,0xA)->()|_-> failwith "didn't match"
116
123
match"111AAA"with Like "%B%s"(0b111,"AAA")->()|_-> failwith "didn't match"
0 commit comments