aboutsummaryrefslogtreecommitdiff
path: root/src/types.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2021-10-20 17:00:14 +0100
committergingerBill <bill@gingerbill.org>2021-10-20 17:00:14 +0100
commite6f725dc2c71d960defda3aa549b47e0cd043c70 (patch)
tree545853b0671c389766fae2209d9696912d0d4307 /src/types.cpp
parent3e4c2e49320b6ddd905b38fc884ec47aa8da7748 (diff)
Minor fix for parapoly matrix types
Diffstat (limited to 'src/types.cpp')
-rw-r--r--src/types.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/types.cpp b/src/types.cpp
index 32e26bcc6..716ebe31f 100644
--- a/src/types.cpp
+++ b/src/types.cpp
@@ -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) {
+ t = base_type(t);
if (is_type_integer(t)) {
return true;
} else if (is_type_float(t)) {
return true;
} else if (is_type_complex(t)) {
return true;
+ }
+ if (t->kind == Type_Generic) {
+ return true;
}
return false;
}