class Myst::Printer
- Myst::Printer
- Reference
- Object
Defined in:
myst/tools/printer.crConstructors
Class Method Summary
Instance Method Summary
- #print(node, io : IO)
- #print(node)
- #replace(node : Node, new_node : Node)
-
#replacements : Hash(UInt64, Node)
#replacements
is a Hash containing mappings from Node instances to other Nodes that should be used in their place when recursing through a program tree. -
#replacements=(replacements : Hash(UInt64, Node))
#replacements
is a Hash containing mappings from Node instances to other Nodes that should be used in their place when recursing through a program tree. - #visit(node : Nop, io : IO)
- #visit(node : Expressions, io : IO)
- #visit(node : NilLiteral, io : IO)
- #visit(node : BooleanLiteral, io : IO)
- #visit(node : IntegerLiteral, io : IO)
- #visit(node : FloatLiteral, io : IO)
- #visit(node : StringLiteral, io : IO)
- #visit(node : SymbolLiteral, io : IO)
- #visit(node : ListLiteral, io : IO)
- #visit(node : MapLiteral, io : IO)
- #visit(node : Var, io : IO)
- #visit(node : Const, io : IO)
- #visit(node : Underscore, io : IO)
- #visit(node : IVar, io : IO)
- #visit(node : ValueInterpolation, io : IO)
- #visit(node : SimpleAssign, io : IO)
- #visit(node : Or, io : IO)
- #visit(node : And, io : IO)
- #visit(node : Splat, io : IO)
- #visit(node : Not, io : IO)
- #visit(node : Negation, io : IO)
- #visit(node : Call, io : IO)
- #visit(node : Param, io : IO)
- #visit(node : ModuleDef, io : IO)
- #visit(node : TypeDef, io : IO)
- #visit(node : Def, io : IO)
-
#visit(node : Node, io : IO)
Catch all for unimplemented nodes
Macro Summary
Constructor Detail
Class Method Detail
Instance Method Detail
#replacements
is a Hash containing mappings from Node instances
to other Nodes that should be used in their place when recursing through
a program tree. This is useful for performing code rewrites
programmatically without having to modify the original program.
#replacements
is a Hash containing mappings from Node instances
to other Nodes that should be used in their place when recursing through
a program tree. This is useful for performing code rewrites
programmatically without having to modify the original program.