aboutsummaryrefslogtreecommitdiff
path: root/src/compile.h
blob: 211763954c610f9ea401490955692533afd48ea8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#pragma once

// Compilation functions

#include <gc.h>

#include "environment.h"
#include "stdlib/datatypes.h"

Text_t expr_as_text(Text_t expr, type_t *t, Text_t color);
Text_t compile_file(env_t *env, ast_t *ast);
Text_t compile_file_header(env_t *env, Path_t header_path, ast_t *ast);
Text_t compile_declaration(type_t *t, Text_t name);
Text_t compile_type(type_t *t);
Text_t compile(env_t *env, ast_t *ast);
Text_t compile_namespace_header(env_t *env, const char *ns_name, ast_t *block);
Text_t compile_statement(env_t *env, ast_t *ast);
Text_t compile_statement_type_header(env_t *env, Path_t header_path, ast_t *ast);
Text_t compile_statement_namespace_header(env_t *env, Path_t header_path, ast_t *ast);
Text_t compile_type_info(type_t *t);
Text_t compile_cli_arg_call(env_t *env, Text_t fn_name, type_t *fn_type, const char *version);

// vim: ts=4 sw=0 et cino=L2,l1,(0,W4,m1,\:0