Class: Delorean::GetAttr
- Defined in:
- lib/delorean/nodes.rb
Instance Method Summary collapse
Instance Method Details
#check(context) ⇒ Object
318 319 320 |
# File 'lib/delorean/nodes.rb', line 318 def check(context, *) [] end |
#rewrite(context, vcode) ⇒ Object
322 323 324 325 326 |
# File 'lib/delorean/nodes.rb', line 322 def rewrite(context, vcode) attr = i.text_value attr = "'#{attr}'" unless attr =~ /\A[0-9]+\z/ "_get_attr(#{vcode}, #{attr}, _e)" end |