diff options
| author | Ginger Bill <bill@gingerbill.org> | 2016-09-08 00:23:14 +0100 |
|---|---|---|
| committer | Ginger Bill <bill@gingerbill.org> | 2016-09-08 00:23:14 +0100 |
| commit | c6d02e4778486c350a732105b6413ba1d32a234a (patch) | |
| tree | 5b1dd564dd1e9c96dcf237cc06b3a09fba8854b2 /src/checker/expr.cpp | |
| parent | 3d02f8a5fdcd18f08083994a51ac9518fc565f79 (diff) | |
Fix missing `type_info` with manual linear search
Diffstat (limited to 'src/checker/expr.cpp')
| -rw-r--r-- | src/checker/expr.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/checker/expr.cpp b/src/checker/expr.cpp index 5e97727fd..7bf131f05 100644 --- a/src/checker/expr.cpp +++ b/src/checker/expr.cpp @@ -91,8 +91,6 @@ b32 check_is_assignable_to(Checker *c, Operand *operand, Type *type, b32 is_argu Type *s = operand->type; - - if (are_types_identical(s, type)) { return true; } @@ -179,6 +177,7 @@ void check_assignment(Checker *c, Operand *operand, Type *type, String context_n Type *target_type = type; if (type == NULL || is_type_any(type)) { + add_type_info_type(c, type); target_type = default_type(operand->type); } convert_to_typed(c, operand, target_type); @@ -795,11 +794,6 @@ void check_identifier(Checker *c, Operand *o, AstNode *n, Type *named_type, Cycl o->mode = Addressing_Builtin; break; - case Entity_UsingVariable: - // TODO(bill): Entity_UsingVariable: is this correct? - o->mode = Addressing_Variable; - break; - default: GB_PANIC("Compiler error: Unknown EntityKind"); break; |