File tree Expand file tree Collapse file tree 2 files changed +27
-1
lines changed
Sources/_StringProcessing Expand file tree Collapse file tree 2 files changed +27
-1
lines changed Original file line number Diff line number Diff line change @@ -778,7 +778,7 @@ extension DSLTree.Atom.CharacterClass {
778
778
case . verticalWhitespace:
779
779
return " .verticalWhitespace "
780
780
case . notVerticalWhitespace:
781
- return " .vertialWhitespace .inverted "
781
+ return " .verticalWhitespace .inverted "
782
782
case . whitespace:
783
783
return " .whitespace "
784
784
case . notWhitespace:
Original file line number Diff line number Diff line change @@ -135,6 +135,32 @@ extension RenderDSLTests {
135
135
}
136
136
}
137
137
"""# )
138
+
139
+ try testConversion ( #"a(?:\w|\W)b(?:\d|\D)c(?:\v|\V)d(?:\h|\H)e"# , #"""
140
+ Regex {
141
+ "a"
142
+ ChoiceOf {
143
+ One(.word)
144
+ One(.word.inverted)
145
+ }
146
+ "b"
147
+ ChoiceOf {
148
+ One(.digit)
149
+ One(.digit.inverted)
150
+ }
151
+ "c"
152
+ ChoiceOf {
153
+ One(.verticalWhitespace)
154
+ One(.verticalWhitespace.inverted)
155
+ }
156
+ "d"
157
+ ChoiceOf {
158
+ One(.horizontalWhitespace)
159
+ One(.horizontalWhitespace.inverted)
160
+ }
161
+ "e"
162
+ }
163
+ """# )
138
164
}
139
165
140
166
func testOptions( ) throws {
You can’t perform that action at this time.
0 commit comments