@@ -219,9 +219,12 @@ Examples:
219
219
220
220
multi sub comb(Str:D $matcher, Str:D $input, $limit = Inf)
221
221
multi sub comb(Regex:D $matcher, Str:D $input, $limit = Inf, Bool :$match)
222
+ multi sub comb(Int:D $size, Str:D $input, $limit = Inf)
223
+
222
224
multi method comb(Str:D $input:)
223
225
multi method comb(Str:D $input: Str:D $matcher, $limit = Inf)
224
226
multi method comb(Str:D $input: Regex:D $matcher, $limit = Inf, Bool :$match)
227
+ multi method comb(Str:D $input: Int:D $size, $limit = Inf)
225
228
226
229
Searches for C < $matcher > in C < $input > and returns a list of all matches
227
230
(as C < Str > by default, or as L < Match > if C < $match > is True), limited to at most
@@ -237,6 +240,9 @@ Examples:
237
240
comb(/\w/, "a;b;c", 2).perl; # ("a", "b").list
238
241
comb(/\w\;\w/, "a;b;c", 2).perl; # ("a;b",).list
239
242
243
+ If the matcher is an integer value, it is considered to be a matcher that
244
+ is similar to / . ** matcher /, but which is about 30x faster.
245
+
240
246
= head2 routine lines
241
247
242
248
multi sub lines(Str:D $input, $limit = Inf) returns Positional
0 commit comments