]> git.xonotic.org Git - xonotic/gmqcc.git/commitdiff
for ast_value_codegen this should be enough, since the actual generation happens...
authorWolfgang (Blub) Bumiller <blub@speed.at>
Wed, 2 May 2012 16:25:59 +0000 (18:25 +0200)
committerWolfgang (Blub) Bumiller <blub@speed.at>
Wed, 2 May 2012 16:25:59 +0000 (18:25 +0200)
ast.c

diff --git a/ast.c b/ast.c
index 63787cd547d0f56582c8689212bd583ea6f91896..af64e0847730f4d71111d0fe4223d9fb5aa17ecf 100644 (file)
--- a/ast.c
+++ b/ast.c
@@ -309,7 +309,10 @@ bool ast_value_codegen(ast_value *self, ast_function *func, bool lvalue, ir_valu
      * and the ast-user should take care of ast_global_codegen to be used
      * on all the globals.
      */
-    return false;
+    if (!self->ir_v)
+        return false;
+    *out = self->ir_v;
+    return true;
 }
 
 bool ast_global_codegen(ast_value *self, ir_builder *ir)