Skip to content
Snippets Groups Projects
Verified Commit 7d28bd5e authored by Justin Carpentier's avatar Justin Carpentier
Browse files

core: fix issue with Vector types

a vector should be either C or F continuous
parent 15b701a9
No related branches found
No related tags found
No related merge requests found
...@@ -245,7 +245,8 @@ inline bool is_arr_layout_compatible_with_mat_type(PyArrayObject *pyArray) { ...@@ -245,7 +245,8 @@ inline bool is_arr_layout_compatible_with_mat_type(PyArrayObject *pyArray) {
bool is_array_F_cont = PyArray_IS_F_CONTIGUOUS(pyArray); bool is_array_F_cont = PyArray_IS_F_CONTIGUOUS(pyArray);
return (MatType::IsRowMajor && is_array_C_cont) || return (MatType::IsRowMajor && is_array_C_cont) ||
(!MatType::IsRowMajor && is_array_F_cont) || (!MatType::IsRowMajor && is_array_F_cont) ||
MatType::IsVectorAtCompileTime; (MatType::IsVectorAtCompileTime &&
(is_array_C_cont || is_array_F_cont));
} }
template <typename MatType, int Options, typename Stride> template <typename MatType, int Options, typename Stride>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment