[rubygems/rubygems] Avoid calling String#dup in Gem::Version#marshal_dump

Might potentially save a second every time RubyGems.org creates a specs index

https://github.com/rubygems/rubygems/commit/d6e4d50f8d
This commit is contained in:
Samuel Giddins 2023-03-06 17:13:49 -08:00 committed by git
parent dc33d32f12
commit 638f68b2fe

View File

@ -272,7 +272,7 @@ class Gem::Version
# string for backwards (RubyGems 1.3.5 and earlier) compatibility. # string for backwards (RubyGems 1.3.5 and earlier) compatibility.
def marshal_dump def marshal_dump
[version] [@version]
end end
## ##