Fix some ref/map/block non-trivial interactions.
This commit is contained in:
parent
f285251a52
commit
399f17af57
7 changed files with 127 additions and 22 deletions
|
|
@ -58,11 +58,19 @@ namespace rotgen
|
|||
map& operator=(const map&) = default;
|
||||
map& operator=(map&&) = default;
|
||||
|
||||
map(ptr_type ptr, Index r, Index c, stride_type s) : parent(ptr, r, c, strides<storage_order>(s)) {}
|
||||
map(ptr_type ptr, Index r, Index c) : parent(ptr, r, c, strides<storage_order>(r,c)) {}
|
||||
map(ptr_type ptr, Index r, Index c, stride_type s) : parent(ptr, r, c, strides<storage_order>(s,r,c)) {}
|
||||
map(ptr_type ptr, Index r, Index c)
|
||||
: parent( ptr, r, c
|
||||
, [&]()
|
||||
{
|
||||
if constexpr(!std::same_as<Stride,stride>) return strides<storage_order>(Stride{},r,c);
|
||||
else return strides<storage_order>(r,c);
|
||||
}()
|
||||
)
|
||||
{}
|
||||
|
||||
map(ptr_type ptr, stride_type s) requires(RowsAtCompileTime!=-1 && ColsAtCompileTime!=-1)
|
||||
: parent(ptr, strides<storage_order>(s))
|
||||
: parent(ptr, strides<storage_order>(s,RowsAtCompileTime,ColsAtCompileTime))
|
||||
{}
|
||||
|
||||
map(ptr_type ptr, Index sz) requires(RowsAtCompileTime==1 || ColsAtCompileTime==1)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue