mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
18 lines
228 B
YAML
18 lines
228 B
YAML
|
prelude: |
|
||
|
class C < Array
|
||
|
attr_reader :a, :b, :c
|
||
|
def initialize
|
||
|
@a = nil
|
||
|
@b = nil
|
||
|
@c = nil
|
||
|
end
|
||
|
end
|
||
|
|
||
|
c = C.new
|
||
|
benchmark:
|
||
|
vm_ivar_generic_get: |
|
||
|
c.a
|
||
|
c.b
|
||
|
c.c
|
||
|
loop_count: 30000000
|