Class: Delorean::BlockFormula
- Defined in:
- lib/delorean/nodes.rb
Instance Method Summary collapse
- #check(context) ⇒ Object
- #force_def(context) ⇒ Object
- #force_undef(context) ⇒ Object
- #rewrite(context) ⇒ Object
Instance Method Details
#check(context) ⇒ Object
456 457 458 459 460 461 462 463 464 465 466 467 |
# File 'lib/delorean/nodes.rb', line 456 def check(context, *) if i.text_value.include?('?') raise Delorean::ParseError.new( '? in formula names not supported', context.module_name, context.line_no ) end context.parse_define_var(i.text_value) context.parse_undef_var(i.text_value) end |
#force_def(context) ⇒ Object
473 474 475 |
# File 'lib/delorean/nodes.rb', line 473 def force_def(context) context.parse_define_var(i.text_value) end |
#force_undef(context) ⇒ Object
477 478 479 |
# File 'lib/delorean/nodes.rb', line 477 def force_undef(context) context.parse_undef_var(i.text_value) end |
#rewrite(context) ⇒ Object
469 470 471 |
# File 'lib/delorean/nodes.rb', line 469 def rewrite(context) "#{i.text_value}#{POST} = #{e.rewrite(context)}" end |