-
-
Save jasonmay/9e8d68cfeefe4895df40 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val num_nodes: PartialFunction[AST, MoeObject] = { | |
case IntLiteralNode => eval(...) | |
} | |
val loop_nodes: PartialFunction[AST, MoeObject] = { | |
case ForNode => eval(...) | |
} | |
val all_nodes = num_nodes orElse loop_nodes orElse etc | |
val result = all_nodes(ast) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment