mirror of
https://github.com/odin-lang/Odin.git
synced 2026-05-25 13:18:14 +00:00
Support ([N]T)([N]U{...})
This commit is contained in:
@@ -3460,8 +3460,13 @@ gb_internal bool check_is_castable_to(CheckerContext *c, Operand *operand, Type
|
||||
|
||||
|
||||
if (dst->kind == Type_Array && src->kind == Type_Array) {
|
||||
if (are_types_identical(dst->Array.elem, src->Array.elem)) {
|
||||
return dst->Array.count == src->Array.count;
|
||||
if (dst->Array.count == src->Array.count) {
|
||||
if (are_types_identical(dst->Array.elem, src->Array.elem)) {
|
||||
return true;
|
||||
}
|
||||
Operand op = *operand;
|
||||
op.type = src->Array.elem;
|
||||
return check_is_castable_to(c, &op, dst->Array.elem);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user