summaryrefslogtreecommitdiff
path: root/tool/ruby_vm/models/attribute.rb
diff options
context:
space:
mode:
authorshyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-12 08:38:11 +0000
committershyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-01-12 08:38:11 +0000
commit8a72c77c7920d129818b7b83bb4fa669cd7e3f7d (patch)
treee88e17811fdb1059cc3a63199c297582780c8497 /tool/ruby_vm/models/attribute.rb
parent069e9ff52cbb01fe2c5821a9b6a8077ab59c26c7 (diff)
tool/ruby_vm support for pre-2.1 BASERUBY
as requested by devs, support for BASERUBY prior to 2.1 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61786 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'tool/ruby_vm/models/attribute.rb')
-rw-r--r--tool/ruby_vm/models/attribute.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/tool/ruby_vm/models/attribute.rb b/tool/ruby_vm/models/attribute.rb
index 0b6d6e09b2..f6d95bd67c 100644
--- a/tool/ruby_vm/models/attribute.rb
+++ b/tool/ruby_vm/models/attribute.rb
@@ -16,11 +16,11 @@ class RubyVM::Attribute
include RubyVM::CEscape
attr_reader :insn, :key, :type, :expr
- def initialize insn:, name:, type:, location:, expr:
- @insn = insn
- @key = name
- @expr = RubyVM::CExpr.new location: location, expr: expr
- @type = type
+ def initialize opts = {}
+ @insn = opts[:insn]
+ @key = opts[:name]
+ @expr = RubyVM::CExpr.new location: opts[:location], expr: opts[:expr]
+ @type = opts[:type]
end
def name