]> de.git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - ast.h
creating and generating builtin functions, ast-macros for builtins, todo: params
[xonotic/gmqcc.git] / ast.h
diff --git a/ast.h b/ast.h
index f355716f70d04aeb39fa33f656b1d42217d2f3b6..a08c4c0d4072d5df8bd61cacaff8fd971c59b704 100644 (file)
--- a/ast.h
+++ b/ast.h
@@ -343,6 +343,8 @@ struct ast_function_s
     ast_value  *vtype;
     const char *name;
 
+    int builtin;
+
     ir_function *ir_func;
     ir_block    *curblock;
     ir_block    *breakblock;
@@ -356,6 +358,7 @@ struct ast_function_s
     char         labelbuf[64];
 
     MEM_VECTOR_MAKE(ast_block*, blocks);
+    MEM_VECTOR_MAKE(ast_value*, params);
 };
 ast_function* ast_function_new(lex_ctx ctx, const char *name, ast_value *vtype);
 /* This will NOT delete the underlying ast_value */
@@ -366,6 +369,7 @@ void ast_function_delete(ast_function*);
 const char* ast_function_label(ast_function*, const char *prefix);
 
 MEM_VECTOR_PROTO(ast_function, ast_block*, blocks);
+MEM_VECTOR_PROTO(ast_function, ast_value*, params);
 
 bool ast_function_codegen(ast_function *self, ir_builder *builder);