]> git.rm.cloudns.org Git - xonotic/gmqcc.git/commitdiff
removing ir_function_get_local - it's unused
authorWolfgang (Blub) Bumiller <blub@speed.at>
Sun, 25 Nov 2012 12:33:00 +0000 (13:33 +0100)
committerWolfgang (Blub) Bumiller <blub@speed.at>
Sun, 25 Nov 2012 12:33:00 +0000 (13:33 +0100)
ir.c
ir.h

diff --git a/ir.c b/ir.c
index 6c1e58995a8b91a28a97841098d6980726d1c8ef..95ff8d2f8eb10c35003038c16f295a97d7e555c3 100644 (file)
--- a/ir.c
+++ b/ir.c
@@ -547,25 +547,10 @@ bool ir_function_finalize(ir_function *self)
     return true;
 }
 
-ir_value* ir_function_get_local(ir_function *self, const char *name)
-{
-    size_t i;
-    for (i = 0; i < vec_size(self->locals); ++i) {
-        if (!strcmp(self->locals[i]->name, name))
-            return self->locals[i];
-    }
-    return NULL;
-}
-
 ir_value* ir_function_create_local(ir_function *self, const char *name, int vtype, bool param)
 {
     ir_value *ve;
 
-    /*
-    if (ir_function_get_local(self, name))
-        return NULL;
-    */
-
     if (param &&
         vec_size(self->locals) &&
         self->locals[vec_size(self->locals)-1]->store != store_param) {
diff --git a/ir.h b/ir.h
index bb26cff2ae2f8c0ed31ae2bc258dd896532860ce..324335fe833d375a476467bceecf8d38d6af5d04 100644 (file)
--- a/ir.h
+++ b/ir.h
@@ -271,7 +271,6 @@ void ir_function_collect_value(ir_function*, ir_value *value);
 
 bool ir_function_set_name(ir_function*, const char *name);
 
-ir_value* ir_function_get_local(ir_function *self, const char *name);
 ir_value* ir_function_create_local(ir_function *self, const char *name, int vtype, bool param);
 
 bool GMQCC_WARN ir_function_finalize(ir_function*);