Add intrinsics.type_hasher_proc; Make map work with generic hasher procedure

This commit is contained in:
gingerBill
2020-11-29 15:27:53 +00:00
parent 085972bb2c
commit 97c66c9c73
11 changed files with 338 additions and 99 deletions

View File

@@ -690,7 +690,8 @@ gb_global Type *t_map_header = nullptr;
gb_global Type *t_vector_x86_mmx = nullptr;
gb_global Type *t_equal_proc = nullptr;
gb_global Type *t_equal_proc = nullptr;
gb_global Type *t_hasher_proc = nullptr;
i64 type_size_of (Type *t);
@@ -1949,6 +1950,9 @@ bool is_type_simple_compare(Type *t) {
if (t->Basic.flags & BasicFlag_SimpleCompare) {
return true;
}
if (t->Basic.kind == Basic_typeid) {
return true;
}
return false;
case Type_Pointer: