mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
As proposed on the list:
- rename EvalBeforeAssignBit to MayAliasBit - make .lazy() remove the MayAliasBit only, and mark it as deprecated - add a NoAlias pseudo expression, and MatrixBase::noalias() function Todo: - we have to decide whether += and -= assume no aliasing by default ? - once we agree on the API: update the Sparse module and the unit tests respectively.
This commit is contained in:
@@ -25,7 +25,9 @@
|
||||
#ifndef EIGEN_FLAGGED_H
|
||||
#define EIGEN_FLAGGED_H
|
||||
|
||||
/** \class Flagged
|
||||
/** \deprecated it is only used by lazy() which is deprecated
|
||||
*
|
||||
* \class Flagged
|
||||
*
|
||||
* \brief Expression with modified flags
|
||||
*
|
||||
@@ -111,9 +113,9 @@ template<typename ExpressionType, unsigned int Added, unsigned int Removed> clas
|
||||
ExpressionTypeNested m_matrix;
|
||||
};
|
||||
|
||||
/** \returns an expression of *this with added flags
|
||||
/** \deprecated it is only used by lazy() which is deprecated
|
||||
*
|
||||
* \addexample MarkExample \label How to mark a triangular matrix as triangular
|
||||
* \returns an expression of *this with added flags
|
||||
*
|
||||
* Example: \include MatrixBase_marked.cpp
|
||||
* Output: \verbinclude MatrixBase_marked.out
|
||||
@@ -128,8 +130,9 @@ MatrixBase<Derived>::marked() const
|
||||
return derived();
|
||||
}
|
||||
|
||||
/** \returns an expression of *this with the following flags removed:
|
||||
* EvalBeforeNestingBit and EvalBeforeAssigningBit.
|
||||
/** \deprecated use MatrixBase::noalias()
|
||||
*
|
||||
* \returns an expression of *this with the MayAliasBit flag removed.
|
||||
*
|
||||
* Example: \include MatrixBase_lazy.cpp
|
||||
* Output: \verbinclude MatrixBase_lazy.out
|
||||
@@ -137,7 +140,7 @@ MatrixBase<Derived>::marked() const
|
||||
* \sa class Flagged, marked()
|
||||
*/
|
||||
template<typename Derived>
|
||||
inline const Flagged<Derived, 0, EvalBeforeNestingBit | EvalBeforeAssigningBit>
|
||||
inline const Flagged<Derived, 0, MayAliasBit>
|
||||
MatrixBase<Derived>::lazy() const
|
||||
{
|
||||
return derived();
|
||||
|
||||
Reference in New Issue
Block a user