erb.rb: Tiny improvement of compiling cost
by reducing string allocation. * Before app_erb 0.687 * After app_erb 0.679 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@58908 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
9f9f8236ff
commit
43572889b3
@ -582,7 +582,7 @@ class ERB
|
||||
def content_dump(s) # :nodoc:
|
||||
n = s.count("\n")
|
||||
if n > 0
|
||||
s.dump + "\n" * n
|
||||
s.dump << "\n" * n
|
||||
else
|
||||
s.dump
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user