mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-08-13 12:19:12 +08:00
Expose InnerSizeAtCompileTime in SparseMatrixBase (it was already present in DenseBase) and simplify sparse_vector_assign_selector (this also fix a stupid warning in old gcc versions)
This commit is contained in:
parent
f2aba7a768
commit
adeaa657eb
@ -89,6 +89,9 @@ template<typename Derived> class SparseMatrixBase : public EigenBase<Derived>
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
IsRowMajor = Flags&RowMajorBit ? 1 : 0,
|
IsRowMajor = Flags&RowMajorBit ? 1 : 0,
|
||||||
|
|
||||||
|
InnerSizeAtCompileTime = int(IsVectorAtCompileTime) ? int(SizeAtCompileTime)
|
||||||
|
: int(IsRowMajor) ? int(ColsAtCompileTime) : int(RowsAtCompileTime),
|
||||||
|
|
||||||
#ifndef EIGEN_PARSED_BY_DOXYGEN
|
#ifndef EIGEN_PARSED_BY_DOXYGEN
|
||||||
_HasDirectAccess = (int(Flags)&DirectAccessBit) ? 1 : 0 // workaround sunCC
|
_HasDirectAccess = (int(Flags)&DirectAccessBit) ? 1 : 0 // workaround sunCC
|
||||||
|
@ -55,9 +55,8 @@ enum {
|
|||||||
|
|
||||||
template< typename Dest, typename Src,
|
template< typename Dest, typename Src,
|
||||||
int AssignmentKind = !bool(Src::IsVectorAtCompileTime) ? SVA_RuntimeSwitch
|
int AssignmentKind = !bool(Src::IsVectorAtCompileTime) ? SVA_RuntimeSwitch
|
||||||
: (((Src::Flags&RowMajorBit)==RowMajorBit) && (Src::RowsAtCompileTime==1))
|
: Src::InnerSizeAtCompileTime==1 ? SVA_Outer
|
||||||
|| ((((Src::Flags&RowMajorBit)==0) && (Src::ColsAtCompileTime==1))) ? SVA_Inner
|
: SVA_Inner>
|
||||||
: SVA_Outer>
|
|
||||||
struct sparse_vector_assign_selector;
|
struct sparse_vector_assign_selector;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user