From 3be20840caa484e6f07865338bac57de45765c81 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Mon, 14 May 2018 15:39:12 -0700 Subject: Removing dead code. --- nomsu.lua | 32 -------------------------------- 1 file changed, 32 deletions(-) (limited to 'nomsu.lua') diff --git a/nomsu.lua b/nomsu.lua index 3a2679d..7329c2e 100644 --- a/nomsu.lua +++ b/nomsu.lua @@ -508,38 +508,6 @@ do end return nil end, - print_tree = function(self, tree) - io.write(colors.bright .. colors.green) - for node, depth in coroutine.wrap(function() - return self:walk_tree(tree) - end) do - if Types.is_node(node) then - print(tostring((" "):rep(depth)) .. tostring(node.type) .. ":") - else - print((" "):rep(depth) .. repr(node)) - end - end - return io.write(colors.reset) - end, - tree_to_str = function(self, tree) - local bits = { } - for node, depth in coroutine.wrap(function() - return self:walk_tree(tree) - end) do - if Types.is_node(node) then - insert(bits, (tostring((" "):rep(depth)) .. tostring(node.type) .. ":")) - else - insert(bits, ((" "):rep(depth) .. repr(node))) - end - end - return concat(bits, "\n") - end, - tree_map = function(self, tree, fn) - if not (Types.is_node(tree)) then - return tree - end - return tree:map(fn) - end, tree_with_replaced_vars = function(self, tree, replacements) if not (next(replacements)) then return tree -- cgit v1.2.3