| ... | ... | @@ -6369,10 +6369,7 @@ static ImplicitCastMatchResult ir_types_match_with_implicit_cast(IrAnalyze *ira, |
| 6369 | 6369 | } |
| 6370 | 6370 | |
| 6371 | 6371 | // implicit [N]T to []const T |
| 6372 | | if (expected_type->id == TypeTableEntryIdStruct && |
| 6373 | | expected_type->data.structure.is_slice && |
| 6374 | | actual_type->id == TypeTableEntryIdArray) |
| 6375 | | { |
| 6372 | if (is_slice(expected_type) && actual_type->id == TypeTableEntryIdArray) { |
| 6376 | 6373 | TypeTableEntry *ptr_type = expected_type->data.structure.fields[slice_ptr_index].type_entry; |
| 6377 | 6374 | assert(ptr_type->id == TypeTableEntryIdPointer); |
| 6378 | 6375 | |
| ... | ... | @@ -6384,8 +6381,7 @@ static ImplicitCastMatchResult ir_types_match_with_implicit_cast(IrAnalyze *ira, |
| 6384 | 6381 | } |
| 6385 | 6382 | |
| 6386 | 6383 | // implicit &const [N]T to []const T |
| 6387 | | if (expected_type->id == TypeTableEntryIdStruct && |
| 6388 | | expected_type->data.structure.is_slice && |
| 6384 | if (is_slice(expected_type) && |
| 6389 | 6385 | actual_type->id == TypeTableEntryIdPointer && |
| 6390 | 6386 | actual_type->data.pointer.is_const && |
| 6391 | 6387 | actual_type->data.pointer.child_type->id == TypeTableEntryIdArray) |