c_void is provided outside of C imports

This commit is contained in:
Andrew Kelley
2016-03-01 15:26:41 -07:00
parent 660a50661b
commit 5df091fea9
6 changed files with 15 additions and 23 deletions

View File

@@ -3551,6 +3551,11 @@ static void define_builtin_types(CodeGen *g) {
g->builtin_types.entry_i32 = get_int_type(g, true, 32);
g->builtin_types.entry_i64 = get_int_type(g, true, 64);
{
g->builtin_types.entry_c_void = get_typedecl_type(g, "c_void", g->builtin_types.entry_u8);
g->primitive_type_table.put(&g->builtin_types.entry_c_void->name, g->builtin_types.entry_c_void);
}
{
TypeTableEntry *entry = new_type_table_entry(TypeTableEntryIdPureError);
buf_init_from_str(&entry->name, "error");