mirror of
https://github.com/ruby/ruby.git
synced 2026-01-27 04:24:23 +00:00
escapable character (https://github.com/ruby/erb/pull/87) This change improves reduces allocations and makes `html_escape` ~35% faster in a benchmark with escaped strings taken from the `test_html_escape` test in `test/test_erb.rb`. - Perform buffer allocation on first instance of escapable character. - Instead of copying characters one at a time, copy unescaped segments using `memcpy`. https://github.com/ruby/erb/commit/aa482890fe