aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/SparseCore/SparseAssign.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2014-09-18 15:15:27 +0200
committerGravatar Gael Guennebaud <g.gael@free.fr>2014-09-18 15:15:27 +0200
commit0ca43f7e9a654e32da0066163a8656415961e266 (patch)
treeed0da1fda3880f825eb8e9715546568deeee667f /Eigen/src/SparseCore/SparseAssign.h
parent8b3be4907da2cbf47ec15734b7f364e6e66bf4c3 (diff)
Remove deprecated code not used by evaluators
Diffstat (limited to 'Eigen/src/SparseCore/SparseAssign.h')
-rw-r--r--Eigen/src/SparseCore/SparseAssign.h113
1 files changed, 0 insertions, 113 deletions
diff --git a/Eigen/src/SparseCore/SparseAssign.h b/Eigen/src/SparseCore/SparseAssign.h
index 36c9fe845..97c079d3f 100644
--- a/Eigen/src/SparseCore/SparseAssign.h
+++ b/Eigen/src/SparseCore/SparseAssign.h
@@ -12,117 +12,6 @@
namespace Eigen {
-#ifndef EIGEN_TEST_EVALUATORS
-
-template<typename Derived>
-template<typename OtherDerived>
-Derived& SparseMatrixBase<Derived>::operator=(const EigenBase<OtherDerived> &other)
-{
- other.derived().evalTo(derived());
- return derived();
-}
-
-template<typename Derived>
-template<typename OtherDerived>
-Derived& SparseMatrixBase<Derived>::operator=(const ReturnByValue<OtherDerived>& other)
-{
- other.evalTo(derived());
- return derived();
-}
-
-template<typename Derived>
-template<typename OtherDerived>
-inline Derived& SparseMatrixBase<Derived>::operator=(const SparseMatrixBase<OtherDerived>& other)
-{
- return assign(other.derived());
-}
-
-template<typename Derived>
-inline Derived& SparseMatrixBase<Derived>::operator=(const Derived& other)
-{
-// if (other.isRValue())
-// derived().swap(other.const_cast_derived());
-// else
- return assign(other.derived());
-}
-
-template<typename Derived>
-template<typename OtherDerived>
-inline Derived& SparseMatrixBase<Derived>::assign(const OtherDerived& other)
-{
- const bool transpose = (Flags & RowMajorBit) != (OtherDerived::Flags & RowMajorBit);
- const Index outerSize = (int(OtherDerived::Flags) & RowMajorBit) ? Index(other.rows()) : Index(other.cols());
- if ((!transpose) && other.isRValue())
- {
- // eval without temporary
- derived().resize(Index(other.rows()), Index(other.cols()));
- derived().setZero();
- derived().reserve((std::max)(this->rows(),this->cols())*2);
- for (Index j=0; j<outerSize; ++j)
- {
- derived().startVec(j);
- for (typename OtherDerived::InnerIterator it(other, typename OtherDerived::Index(j)); it; ++it)
- {
- Scalar v = it.value();
- derived().insertBackByOuterInner(j,Index(it.index())) = v;
- }
- }
- derived().finalize();
- }
- else
- {
- assignGeneric(other);
- }
- return derived();
-}
-
-template<typename Derived>
-template<typename OtherDerived>
-inline void SparseMatrixBase<Derived>::assignGeneric(const OtherDerived& other)
-{
- //const bool transpose = (Flags & RowMajorBit) != (OtherDerived::Flags & RowMajorBit);
- eigen_assert(( ((internal::traits<Derived>::SupportedAccessPatterns&OuterRandomAccessPattern)==OuterRandomAccessPattern) ||
- (!((Flags & RowMajorBit) != (OtherDerived::Flags & RowMajorBit)))) &&
- "the transpose operation is supposed to be handled in SparseMatrix::operator=");
-
- enum { Flip = (Flags & RowMajorBit) != (OtherDerived::Flags & RowMajorBit) };
-
- const Index outerSize = Index(other.outerSize());
- //typedef typename internal::conditional<transpose, LinkedVectorMatrix<Scalar,Flags&RowMajorBit>, Derived>::type TempType;
- // thanks to shallow copies, we always eval to a tempary
- Derived temp(Index(other.rows()), Index(other.cols()));
-
- temp.reserve((std::max)(this->rows(),this->cols())*2);
- for (Index j=0; j<outerSize; ++j)
- {
- temp.startVec(j);
- for (typename OtherDerived::InnerIterator it(other.derived(), typename OtherDerived::Index(j)); it; ++it)
- {
- Scalar v = it.value();
- temp.insertBackByOuterInner(Flip?Index(it.index()):j,Flip?j:Index(it.index())) = v;
- }
- }
- temp.finalize();
-
- derived() = temp.markAsRValue();
-}
-
-// template<typename Lhs, typename Rhs>
-// inline Derived& operator=(const SparseSparseProduct<Lhs,Rhs>& product);
-//
-// template<typename OtherDerived>
-// Derived& operator+=(const SparseMatrixBase<OtherDerived>& other);
-// template<typename OtherDerived>
-// Derived& operator-=(const SparseMatrixBase<OtherDerived>& other);
-//
-// Derived& operator*=(const Scalar& other);
-// Derived& operator/=(const Scalar& other);
-//
-// template<typename OtherDerived>
-// Derived& operator*=(const SparseMatrixBase<OtherDerived>& other);
-
-#else // EIGEN_TEST_EVALUATORS
-
template<typename Derived>
template<typename OtherDerived>
Derived& SparseMatrixBase<Derived>::operator=(const EigenBase<OtherDerived> &other)
@@ -298,8 +187,6 @@ struct Assignment<DstXprType, Solve<DecType,RhsType>, internal::assign_op<Scalar
} // end namespace internal
-#endif // EIGEN_TEST_EVALUATORS
-
} // end namespace Eigen
#endif // EIGEN_SPARSEASSIGN_H