unify main entry point regardless of whether linking libc

closes #248
This commit is contained in:
Andrew Kelley
2017-03-22 11:26:30 -04:00
parent e1c47d6fe8
commit 87bc97daef
12 changed files with 86 additions and 57 deletions

View File

@@ -2878,9 +2878,9 @@ ImportTableEntry *add_source_file(CodeGen *g, PackageTableEntry *package,
if (is_pub) {
if (buf_eql_str(proto_name, "main")) {
g->have_exported_main = true;
g->have_pub_main = true;
} else if (buf_eql_str(proto_name, "panic")) {
g->have_exported_panic = true;
g->have_pub_panic = true;
}
}
}