aboutsummaryrefslogtreecommitdiff
path: root/tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'tree.c')
-rw-r--r--tree.c20
1 files changed, 1 insertions, 19 deletions
diff --git a/tree.c b/tree.c
index 4710ac44..f511436a 100644
--- a/tree.c
+++ b/tree.c
@@ -3,7 +3,7 @@
3** TecCGraf - PUC-Rio 3** TecCGraf - PUC-Rio
4*/ 4*/
5 5
6char *rcs_tree="$Id: tree.c,v 1.13 1995/01/12 14:19:04 roberto Exp roberto $"; 6char *rcs_tree="$Id: tree.c,v 1.14 1995/10/17 11:53:53 roberto Exp roberto $";
7 7
8 8
9#include <string.h> 9#include <string.h>
@@ -103,21 +103,3 @@ Long lua_strcollector (void)
103} 103}
104 104
105 105
106/*
107** Traverse the constant tree looking for a specific symbol number
108*/
109static TreeNode *nodebysymbol (TreeNode *root, Word symbol)
110{
111 TreeNode *t;
112 if (root == NULL) return NULL;
113 if (root->varindex == symbol) return root;
114 t = nodebysymbol(root->left, symbol);
115 if (t) return t;
116 return nodebysymbol(root->right, symbol);
117}
118
119TreeNode *luaI_nodebysymbol (Word symbol)
120{
121 return nodebysymbol(constant_root, symbol);
122}
123