mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-07-09 22:51:51 +08:00
compilation fixes with MSVC
This commit is contained in:
parent
2a2c305c4d
commit
75649551c2
@ -36,7 +36,7 @@ struct ei_product_coeff_impl;
|
|||||||
template<int StorageOrder, int Index, typename Lhs, typename Rhs, typename PacketScalar, int LoadMode>
|
template<int StorageOrder, int Index, typename Lhs, typename Rhs, typename PacketScalar, int LoadMode>
|
||||||
struct ei_product_packet_impl;
|
struct ei_product_packet_impl;
|
||||||
|
|
||||||
template<typename T> class ei_product_eval_to_column_major;
|
template<typename T> struct ei_product_eval_to_column_major;
|
||||||
|
|
||||||
/** \class ProductReturnType
|
/** \class ProductReturnType
|
||||||
*
|
*
|
||||||
|
@ -71,9 +71,9 @@ template<typename MatrixType> class LU
|
|||||||
MatrixType::MaxRowsAtCompileTime)
|
MatrixType::MaxRowsAtCompileTime)
|
||||||
};
|
};
|
||||||
|
|
||||||
typedef Matrix<typename MatrixType::Scalar, MatrixType::ColsAtCompileTime, Dynamic,
|
typedef Matrix<typename MatrixType::Scalar, MatrixType::ColsAtCompileTime, Dynamic,
|
||||||
MatrixType::Flags&RowMajorBit,
|
MatrixType::Flags&RowMajorBit,
|
||||||
MatrixType::MaxColsAtCompileTime, MaxSmallDimAtCompileTime> KernelReturnType;
|
MatrixType::MaxColsAtCompileTime, MaxSmallDimAtCompileTime> KernelResultType;
|
||||||
|
|
||||||
/** Constructor.
|
/** Constructor.
|
||||||
*
|
*
|
||||||
@ -150,12 +150,7 @@ template<typename MatrixType> class LU
|
|||||||
*
|
*
|
||||||
* \sa kernel()
|
* \sa kernel()
|
||||||
*/
|
*/
|
||||||
void computeKernel(Matrix<typename MatrixType::Scalar,
|
void computeKernel(KernelResultType *result) const;
|
||||||
MatrixType::ColsAtCompileTime, Dynamic,
|
|
||||||
MatrixType::Flags&RowMajorBit,
|
|
||||||
MatrixType::MaxColsAtCompileTime,
|
|
||||||
LU<MatrixType>::MaxSmallDimAtCompileTime
|
|
||||||
> *result) const;
|
|
||||||
|
|
||||||
/** \returns the kernel of the matrix. The columns of the returned matrix
|
/** \returns the kernel of the matrix. The columns of the returned matrix
|
||||||
* will form a basis of the kernel.
|
* will form a basis of the kernel.
|
||||||
@ -171,7 +166,7 @@ template<typename MatrixType> class LU
|
|||||||
*
|
*
|
||||||
* \sa computeKernel()
|
* \sa computeKernel()
|
||||||
*/
|
*/
|
||||||
const KernelReturnType kernel() const;
|
const KernelResultType kernel() const;
|
||||||
|
|
||||||
/** This method finds a solution x to the equation Ax=b, where A is the matrix of which
|
/** This method finds a solution x to the equation Ax=b, where A is the matrix of which
|
||||||
* *this is the LU decomposition, if any exists.
|
* *this is the LU decomposition, if any exists.
|
||||||
@ -372,12 +367,7 @@ typename ei_traits<MatrixType>::Scalar LU<MatrixType>::determinant() const
|
|||||||
}
|
}
|
||||||
|
|
||||||
template<typename MatrixType>
|
template<typename MatrixType>
|
||||||
void LU<MatrixType>::computeKernel(Matrix<typename MatrixType::Scalar,
|
void LU<MatrixType>::computeKernel(KernelResultType *result) const
|
||||||
MatrixType::ColsAtCompileTime, Dynamic,
|
|
||||||
MatrixType::Flags&RowMajorBit,
|
|
||||||
MatrixType::MaxColsAtCompileTime,
|
|
||||||
LU<MatrixType>::MaxSmallDimAtCompileTime
|
|
||||||
> *result) const
|
|
||||||
{
|
{
|
||||||
ei_assert(!isInvertible());
|
ei_assert(!isInvertible());
|
||||||
const int dimker = dimensionOfKernel(), cols = m_lu.cols();
|
const int dimker = dimensionOfKernel(), cols = m_lu.cols();
|
||||||
@ -414,13 +404,10 @@ void LU<MatrixType>::computeKernel(Matrix<typename MatrixType::Scalar,
|
|||||||
}
|
}
|
||||||
|
|
||||||
template<typename MatrixType>
|
template<typename MatrixType>
|
||||||
const typename LU<MatrixType>::KernelReturnType
|
const typename LU<MatrixType>::KernelResultType
|
||||||
LU<MatrixType>::kernel() const
|
LU<MatrixType>::kernel() const
|
||||||
{
|
{
|
||||||
Matrix<typename MatrixType::Scalar, MatrixType::ColsAtCompileTime, Dynamic,
|
KernelResultType result(m_lu.cols(), dimensionOfKernel());
|
||||||
MatrixType::Flags&RowMajorBit,
|
|
||||||
MatrixType::MaxColsAtCompileTime,
|
|
||||||
LU<MatrixType>::MaxSmallDimAtCompileTime> result(m_lu.cols(), dimensionOfKernel());
|
|
||||||
computeKernel(&result);
|
computeKernel(&result);
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
@ -24,8 +24,6 @@
|
|||||||
|
|
||||||
#include "main.h"
|
#include "main.h"
|
||||||
|
|
||||||
#include <ext/malloc_allocator.h>
|
|
||||||
|
|
||||||
// test compilation with both a struct and a class...
|
// test compilation with both a struct and a class...
|
||||||
struct MyStruct : WithAlignedOperatorNew
|
struct MyStruct : WithAlignedOperatorNew
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user