mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-03 22:28:46 +00:00
Minor fix for parapoly matrix types
This commit is contained in:
@@ -2168,7 +2168,6 @@ bool check_builtin_procedure(CheckerContext *c, Operand *operand, Ast *call, i32
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
case BuiltinProc_simd_vector: {
|
case BuiltinProc_simd_vector: {
|
||||||
Operand x = {};
|
Operand x = {};
|
||||||
Operand y = {};
|
Operand y = {};
|
||||||
|
|||||||
@@ -1313,8 +1313,7 @@ lbValue lb_build_builtin_proc(lbProcedure *p, Ast *expr, TypeAndValue const &tv,
|
|||||||
lbValue m = lb_build_expr(p, ce->args[0]);
|
lbValue m = lb_build_expr(p, ce->args[0]);
|
||||||
return lb_emit_matrix_flatten(p, m, tv.type);
|
return lb_emit_matrix_flatten(p, m, tv.type);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// "Intrinsics"
|
// "Intrinsics"
|
||||||
|
|
||||||
case BuiltinProc_alloca:
|
case BuiltinProc_alloca:
|
||||||
|
|||||||
@@ -1334,12 +1334,16 @@ i64 matrix_indices_to_offset(Type *t, i64 row_index, i64 column_index) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
bool is_type_valid_for_matrix_elems(Type *t) {
|
bool is_type_valid_for_matrix_elems(Type *t) {
|
||||||
|
t = base_type(t);
|
||||||
if (is_type_integer(t)) {
|
if (is_type_integer(t)) {
|
||||||
return true;
|
return true;
|
||||||
} else if (is_type_float(t)) {
|
} else if (is_type_float(t)) {
|
||||||
return true;
|
return true;
|
||||||
} else if (is_type_complex(t)) {
|
} else if (is_type_complex(t)) {
|
||||||
return true;
|
return true;
|
||||||
|
}
|
||||||
|
if (t->kind == Type_Generic) {
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user