mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-06-04 18:54:00 +08:00
fix MSVC stupid warnings
This commit is contained in:
parent
1752a3a677
commit
cf0857c44d
@ -40,10 +40,8 @@ class DiagonalMatrixBase : ei_no_assignment_operator,
|
|||||||
protected:
|
protected:
|
||||||
typedef typename ei_cleantype<CoeffsVectorType>::type _CoeffsVectorType;
|
typedef typename ei_cleantype<CoeffsVectorType>::type _CoeffsVectorType;
|
||||||
|
|
||||||
template<typename OtherDerived,
|
// MSVC gets crazy if we define default parameters
|
||||||
bool IsVector = OtherDerived::IsVectorAtCompileTime,
|
template<typename OtherDerived, bool IsVector, bool IsDiagonal> struct construct_from_expression;
|
||||||
bool IsDiagonal = (OtherDerived::Flags&Diagonal)==Diagonal>
|
|
||||||
struct construct_from_expression;
|
|
||||||
|
|
||||||
// = vector
|
// = vector
|
||||||
template<typename OtherDerived>
|
template<typename OtherDerived>
|
||||||
@ -69,7 +67,8 @@ class DiagonalMatrixBase : ei_no_assignment_operator,
|
|||||||
template<typename OtherDerived>
|
template<typename OtherDerived>
|
||||||
inline DiagonalMatrixBase(const MatrixBase<OtherDerived>& other)
|
inline DiagonalMatrixBase(const MatrixBase<OtherDerived>& other)
|
||||||
{
|
{
|
||||||
construct_from_expression<OtherDerived>::run(derived(),other.derived());
|
construct_from_expression<OtherDerived,OtherDerived::IsVectorAtCompileTime,(OtherDerived::Flags&Diagonal)==Diagonal>
|
||||||
|
::run(derived(),other.derived());
|
||||||
}
|
}
|
||||||
|
|
||||||
public:
|
public:
|
||||||
@ -93,7 +92,8 @@ class DiagonalMatrixBase : ei_no_assignment_operator,
|
|||||||
template<typename OtherDerived>
|
template<typename OtherDerived>
|
||||||
inline Derived& operator=(const MatrixBase<OtherDerived>& other)
|
inline Derived& operator=(const MatrixBase<OtherDerived>& other)
|
||||||
{
|
{
|
||||||
construct_from_expression<OtherDerived>::run(derived(),other);
|
construct_from_expression<OtherDerived,OtherDerived::IsVectorAtCompileTime,(OtherDerived::Flags&Diagonal)==Diagonal>
|
||||||
|
::run(derived(),other);
|
||||||
return derived();
|
return derived();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user