code / tomo

Lines41.3K C23.7K Markdown9.7K YAML5.0K Tomo2.3K
7 others 763
Python231 Shell230 make212 INI47 Text21 SVG16 Lua6
(14 lines)
1 // This file defines how to compile structs
3 #pragma once
5 #include "../ast.h"
6 #include "../environment.h"
7 #include "../types.h"
9 Text_t compile_empty_struct(type_t *t);
10 Text_t compile_struct_typeinfo(env_t *env, type_t *t, const char *name, arg_ast_t *fields, bool is_secret,
11 bool is_opaque);
12 Text_t compile_struct_header(env_t *env, ast_t *ast);
13 Text_t compile_struct_field_access(env_t *env, ast_t *ast);
14 Text_t compile_struct_literal(env_t *env, ast_t *ast, type_t *t, arg_ast_t *args);