diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2016-02-08 15:48:59 -0800 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2016-02-08 15:48:59 -0800 |
commit | 783858c8e150eb0f98d7e5d893e492ee08998662 (patch) | |
tree | 5e1709c30b843ce447c9f458a128a3930ebc7036 /guides/source/active_record_validations.md | |
parent | 02c3867882d6d23b10df262a6db5f937ca69fb53 (diff) | |
download | rails-783858c8e150eb0f98d7e5d893e492ee08998662.tar.gz rails-783858c8e150eb0f98d7e5d893e492ee08998662.tar.bz2 rails-783858c8e150eb0f98d7e5d893e492ee08998662.zip |
drop array allocations on `html_safe`
For better or worse, anonymous `*` args will allocate arrays. Ideally,
the interpreter would optimize away this allocation. However, given the
number of times we call `html_safe` it seems worth the shedding idealism
and going for performance. This line was the top allocation spot for a
scaffold (and presumably worse on real applications).
Diffstat (limited to 'guides/source/active_record_validations.md')
0 files changed, 0 insertions, 0 deletions