1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/actionview/test
schneems 1bd578ffe6 Don’t allocate array on no args
When no dependencies are present to be digested there is no reason to build an array just to turn around and turn it back into a string.

The dependencies array is not mutated in this method so we can use the same empty array across all invocations.

Total allocated: 791402 bytes (7294 objects)
Total allocated: 777442 bytes (7132 objects)

(791402 - 777442) / 791402.0 # => 1.76 % speed improvement
2018-09-07 17:33:10 -05:00
..
actionpack Merge pull request #30647 from droptheplot/render-partials-string-locals 2018-04-27 19:17:36 -04:00
activerecord Don’t allocate array on no args 2018-09-07 17:33:10 -05:00
fixtures Fix digesting templates with mixed formats 2018-03-20 06:33:20 -04:00
lib/controller Use frozen string literal in actionview/ 2017-07-24 11:53:43 +03:00
template Don’t allocate array on no args 2018-09-07 17:33:10 -05:00
ujs Fix stoppable events in tests and docs. 2018-04-14 19:44:14 +03:00
abstract_unit.rb Include ActionDispatch::DrawOnce in ActiveSupport::TestCase 2017-09-27 08:51:37 +09:00
active_record_unit.rb Enable Layout/LeadingCommentSpace to not allow cosmetic changes in the future 2017-12-14 17:30:54 +09:00