mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-07-25 06:14:26 +08:00
Update doc (scalar_add_op is now deprecated)
This commit is contained in:
parent
a8c08e8b8e
commit
a9bb653a68
@ -56,13 +56,13 @@ void makeFloor(const MatrixBase<OtherDerived>& other) { derived() = derived().cw
|
|||||||
template<typename OtherDerived>
|
template<typename OtherDerived>
|
||||||
void makeCeil(const MatrixBase<OtherDerived>& other) { derived() = derived().cwiseMax(other.derived()); }
|
void makeCeil(const MatrixBase<OtherDerived>& other) { derived() = derived().cwiseMax(other.derived()); }
|
||||||
|
|
||||||
const CwiseUnaryOp<internal::scalar_add_op<Scalar>, Derived>
|
const CwiseBinaryOp<internal::scalar_sum_op<Scalar>, const Derived, const ConstantReturnType>
|
||||||
operator+(const Scalar& scalar) const
|
operator+(const Scalar& scalar) const
|
||||||
{ return CwiseUnaryOp<internal::scalar_add_op<Scalar>, Derived>(derived(), internal::scalar_add_op<Scalar>(scalar)); }
|
{ return CwiseBinaryOp<internal::scalar_sum_op<Scalar>, const Derived, const ConstantReturnType>(derived(), Constant(rows(),cols(),scalar)); }
|
||||||
|
|
||||||
friend const CwiseUnaryOp<internal::scalar_add_op<Scalar>, Derived>
|
friend const CwiseBinaryOp<internal::scalar_sum_op<Scalar>, const ConstantReturnType, Derived>
|
||||||
operator+(const Scalar& scalar, const MatrixBase<Derived>& mat)
|
operator+(const Scalar& scalar, const MatrixBase<Derived>& mat)
|
||||||
{ return CwiseUnaryOp<internal::scalar_add_op<Scalar>, Derived>(mat.derived(), internal::scalar_add_op<Scalar>(scalar)); }
|
{ return CwiseBinaryOp<internal::scalar_sum_op<Scalar>, const ConstantReturnType, Derived>(Constant(rows(),cols(),scalar), mat.derived()); }
|
||||||
\endcode
|
\endcode
|
||||||
|
|
||||||
Then one can the following declaration in the config.h or whatever prerequisites header file of his project:
|
Then one can the following declaration in the config.h or whatever prerequisites header file of his project:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user