summaryrefslogtreecommitdiff
path: root/test/ruby/test_defined.rb
diff options
context:
space:
mode:
authorYusuke Endoh <mame@ruby-lang.org>2023-12-27 16:57:00 +0900
committergit <svn-admin@ruby-lang.org>2024-10-17 08:54:45 +0000
commit7962b4c342dbf7f71be61ca4b37baf815fd4c0e6 (patch)
tree9844993d83e98c3c48e7d20e1ca98eed0e24a98c /test/ruby/test_defined.rb
parent681787d11f2d71790cec4b2094086e2bb6629ac9 (diff)
[ruby/json] Use `RARRAY_AREF` instead of `rb_ary_entry` to improve performance
It is safe to use `RARRAY_AREF` here because no Ruby code is executed between `RARRAY_LEN` and `RARRAY_AREF`. This speeds up `JSON.generate` by about 4% in a benchmark. https://github.com/ruby/json/commit/c5d80f9fd4
Diffstat (limited to 'test/ruby/test_defined.rb')
0 files changed, 0 insertions, 0 deletions