25 #ifndef FIBER_LVALUE_H_
26 #define FIBER_LVALUE_H_
32 template <
typename Scalar,
class Exp>
37 Size size()
const {
return static_cast<Exp const&
>(*this).size(); }
38 Size rows()
const {
return static_cast<Exp const&
>(*this).rows(); }
39 Size cols()
const {
return static_cast<Exp const&
>(*this).cols(); }
44 return static_cast<Exp const&
>(*this)[i];
48 return static_cast<Exp&
>(*this)(i, j);
52 return static_cast<Exp const&
>(*this)(i, j);
65 for (
int i = 0; i <
rows(); i++) {
66 for (
int j = 0; j <
cols(); j++) {
67 (*this)(i, j) = B(i, j);
76 template <
typename Scalar,
class Exp>
84 #endif // FIBER_LVALUE_H_
Scalar & operator[](Size i)
StreamAssign operator<<(Scalar x)
returns a stream for assignment
expression template for rvalues
StreamAssignment< _LValue< Scalar, Exp > > StreamAssign
Scalar const & operator()(Size i, Size j) const
_LValue< Scalar, Exp > & operator=(_RValue< Scalar, Exp2 > const &B)
Scalar const & operator[](Size i) const
expression template for rvalues
Scalar & operator()(Size i, Size j)
_LValue< Scalar, Exp > & LValue(_LValue< Scalar, Exp > &exp)
Explicitly expose _LValue of an expressions, can be used to help the compiler disambiguate overloads...