Closed leonid-shevtsov closed 3 months ago
This PR replaces scan in parse_block_into_rule_sets! with StringScanner - a more performant API for tokenizing strings.
scan
parse_block_into_rule_sets!
StringScanner
Tenderlove had a post last year about this.
On our benchmarks this shows a 18% improvement in performance measured for overall add_block!. The code has been in production for around 3 years now, unfortunately making changes public takes additional effort.
add_block!
This PR replaces
scan
inparse_block_into_rule_sets!
withStringScanner
- a more performant API for tokenizing strings.Tenderlove had a post last year about this.
On our benchmarks this shows a 18% improvement in performance measured for overall
add_block!
. The code has been in production for around 3 years now, unfortunately making changes public takes additional effort.Pre-Merge Checklist