writeBinaryFile
This commit is contained in:
parent
fe6d690251
commit
53ca7e1b49
@ -60,10 +60,15 @@ str Compiler_constructTokenStr(Compiler* cmp, Token t){
|
||||
return s;
|
||||
}
|
||||
|
||||
static bool compileFile(Compiler* cmp, FILE* f){
|
||||
static bool writeBinaryFile(Compiler* cmp, FILE* f){
|
||||
returnErrorIf_auto(cmp->state != CompilerState_Parsing);
|
||||
cmp->state = CompilerState_Compiling;
|
||||
|
||||
for(u32 i = 0; i < cmp->ast.sections.len; i++){
|
||||
Section* sec = &cmp->ast.sections.data[i];
|
||||
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -146,7 +151,7 @@ bool Compiler_compile(Compiler* cmp, cstr source_file_name, cstr out_file_name,
|
||||
|
||||
if(debug_log)
|
||||
printf("==================================[compiling]==================================\n");
|
||||
success = compileFile(cmp, f);
|
||||
success = writeBinaryFile(cmp, f);
|
||||
fclose(f);
|
||||
if(success){
|
||||
cmp->state = CompilerState_Success;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user