File tree 1 file changed +4
-3
lines changed
Sources/RegexBenchmark/Suite 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -4,14 +4,15 @@ import RegexBuilder
4
4
extension BenchmarkRunner {
5
5
mutating func addReluctantQuant( ) {
6
6
let size = 500000
7
+ let s = String ( repeating: " a " , count: size)
7
8
8
9
let reluctantQuant = Benchmark (
9
10
name: " ReluctantQuant " ,
10
11
regex: Regex {
11
12
OneOrMore ( . any, . reluctant)
12
13
} ,
13
14
ty: . whole,
14
- target: String ( repeating : " a " , count : size )
15
+ target: s
15
16
)
16
17
17
18
let eagarQuantWithTerminal = Benchmark (
@@ -21,7 +22,7 @@ extension BenchmarkRunner {
21
22
" ; "
22
23
} ,
23
24
ty: . whole,
24
- target: String ( repeating : " a " , count : size ) + " ; "
25
+ target: s + " ; "
25
26
)
26
27
27
28
let reluctantQuantWithTerminal = Benchmark (
@@ -31,7 +32,7 @@ extension BenchmarkRunner {
31
32
" ; "
32
33
} ,
33
34
ty: . whole,
34
- target: String ( repeating : " a " , count : size ) + " ; "
35
+ target: s + " ; "
35
36
)
36
37
37
38
register ( reluctantQuant)
You can’t perform that action at this time.
0 commit comments