Allow conversions between matrices of the same element count

This commit is contained in:
gingerBill
2021-10-21 01:34:39 +01:00
parent e0b9475378
commit 48d277a3c4
4 changed files with 50 additions and 38 deletions

View File

@@ -2469,7 +2469,9 @@ bool check_is_castable_to(CheckerContext *c, Operand *operand, Type *y) {
}
if (src->Matrix.row_count != src->Matrix.column_count) {
return false;
i64 src_count = src->Matrix.row_count*src->Matrix.column_count;
i64 dst_count = dst->Matrix.row_count*dst->Matrix.column_count;
return src_count == dst_count;
}
if (dst->Matrix.row_count != dst->Matrix.column_count) {