Previously, `@section` was a statement inside a top-level chunk, which caused issues when the TLC allocated stack memory (the prologue was generated before the `@section`). This way, Nectar source code is now defined as a list of sections, first and foremost.
25 lines
514 B
C
25 lines
514 B
C
#ifndef NTC_H
|
|
#define NTC_H
|
|
|
|
#include<stddef.h>
|
|
#include<stdint.h>
|
|
#include<stdbool.h>
|
|
|
|
const char **ntc_get_import_paths();
|
|
|
|
const char* ntc_get_arg(const char *name);
|
|
|
|
intmax_t ntc_get_int(const char *name);
|
|
intmax_t ntc_get_int_default(const char *name, intmax_t def);
|
|
|
|
union AST;
|
|
void arch_init();
|
|
bool arch_verify_target();
|
|
int arch_ptr_size();
|
|
void arch_normalize_pre(union AST *tlc);
|
|
void arch_normalize(union AST *tlc);
|
|
int cg_attempt_sections(union AST *tlc);
|
|
void cg_go_sections(union AST *tlc);
|
|
|
|
#endif
|