Module: Qrb::Syntax::TypeDef
- Defined in:
- lib/qrb/syntax/type_def.rb
Instance Method Summary collapse
Instance Method Details
#compile(system) ⇒ Object
5 6 7 8 9 10 |
# File 'lib/qrb/syntax/type_def.rb', line 5 def compile(system) t = type.compile(system) t.name = type_name.to_s system.add_type(t) t end |
#to_ast ⇒ Object
12 13 14 |
# File 'lib/qrb/syntax/type_def.rb', line 12 def to_ast [:type_def, type_name.to_s, type.to_ast] end |