Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
String#* takes one argument, and in that case, better not splat the arg
because splatting the argument allocates an extra Array object. benchmark ```ruby s = 'a'.html_safe Benchmark.ips do |x| x.report('') { s * 1 } end ``` result ``` before Warming up -------------------------------------- 216.816k i/100ms Calculating ------------------------------------- 2.341M (± 2.0%) i/s - 11.708M in 5.002555s after Warming up -------------------------------------- 315.118k i/100ms Calculating ------------------------------------- 3.704M (± 1.5%) i/s - 18.592M in 5.020261s ```
- Loading branch information