Class: Sexpir::Sequential
- Defined in:
- lib/sexpir/ast.rb,
lib/sexpir/ast_sexp.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
Returns the value of attribute body.
-
#label ⇒ Object
Returns the value of attribute label.
Attributes inherited from Ast
Instance Method Summary collapse
Methods inherited from Ast
Instance Attribute Details
#body ⇒ Object
Returns the value of attribute body.
58 59 60 |
# File 'lib/sexpir/ast.rb', line 58 def body @body end |
#label ⇒ Object
Returns the value of attribute label.
58 59 60 |
# File 'lib/sexpir/ast.rb', line 58 def label @label end |
Instance Method Details
#sexp ⇒ Object
93 94 95 96 97 98 99 100 101 102 |
# File 'lib/sexpir/ast_sexp.rb', line 93 def sexp code=Code.new label_s=label ? label : "nil" code << "(sequential #{label_s}" code.indent=2 code << body.sexp code.indent=0 code << ")" code end |