Fix global maps and initialize the preload types before

This commit is contained in:
Ginger Bill
2017-02-07 18:13:37 +00:00
parent 219ca0ac46
commit 454d0b5cf5
5 changed files with 27 additions and 13 deletions
+6
View File
@@ -1132,6 +1132,12 @@ void check_map_type(Checker *c, Type *type, AstNode *node) {
gbAllocator a = c->allocator;
{
// NOTE(bill): The preload types may have not been set yet
if (t_map_key == NULL) {
init_preload(c);
}
GB_ASSERT(t_map_key != NULL);
Type *entry_type = make_type_struct(a);
/*