Lines 133-148
class DenseCoeffsBase<Derived,ReadOnlyAc
Link Here
|
133 |
* |
133 |
* |
134 |
* \sa operator[](Index) const, coeffRef(Index), coeff(Index,Index) const |
134 |
* \sa operator[](Index) const, coeffRef(Index), coeff(Index,Index) const |
135 |
*/ |
135 |
*/ |
136 |
|
136 |
|
137 |
EIGEN_DEVICE_FUNC |
137 |
EIGEN_DEVICE_FUNC |
138 |
EIGEN_STRONG_INLINE CoeffReturnType |
138 |
EIGEN_STRONG_INLINE CoeffReturnType |
139 |
coeff(Index index) const |
139 |
coeff(Index index) const |
140 |
{ |
140 |
{ |
|
|
141 |
EIGEN_STATIC_ASSERT(Derived::Flags & LinearAccessBit, |
142 |
THIS_COEFFICIENT_ACCESSOR_TAKING_ONE_ACCESS_IS_ONLY_FOR_EXPRESSIONS_ALLOWING_LINEAR_ACCESS) |
143 |
|
141 |
eigen_internal_assert(index >= 0 && index < size()); |
144 |
eigen_internal_assert(index >= 0 && index < size()); |
142 |
return typename internal::evaluator<Derived>::type(derived()).coeff(index); |
145 |
return typename internal::evaluator<Derived>::type(derived()).coeff(index); |
143 |
} |
146 |
} |
144 |
|
147 |
|
145 |
|
148 |
|
146 |
/** \returns the coefficient at given index. |
149 |
/** \returns the coefficient at given index. |
147 |
* |
150 |
* |
148 |
* This method is allowed only for vector expressions, and for matrix expressions having the LinearAccessBit. |
151 |
* This method is allowed only for vector expressions, and for matrix expressions having the LinearAccessBit. |
Lines 363-378
class DenseCoeffsBase<Derived, WriteAcce
Link Here
|
363 |
* |
366 |
* |
364 |
* \sa operator[](Index), coeff(Index) const, coeffRef(Index,Index) |
367 |
* \sa operator[](Index), coeff(Index) const, coeffRef(Index,Index) |
365 |
*/ |
368 |
*/ |
366 |
|
369 |
|
367 |
EIGEN_DEVICE_FUNC |
370 |
EIGEN_DEVICE_FUNC |
368 |
EIGEN_STRONG_INLINE Scalar& |
371 |
EIGEN_STRONG_INLINE Scalar& |
369 |
coeffRef(Index index) |
372 |
coeffRef(Index index) |
370 |
{ |
373 |
{ |
|
|
374 |
EIGEN_STATIC_ASSERT(Derived::Flags & LinearAccessBit, |
375 |
THIS_COEFFICIENT_ACCESSOR_TAKING_ONE_ACCESS_IS_ONLY_FOR_EXPRESSIONS_ALLOWING_LINEAR_ACCESS) |
371 |
eigen_internal_assert(index >= 0 && index < size()); |
376 |
eigen_internal_assert(index >= 0 && index < size()); |
372 |
return typename internal::evaluator<Derived>::type(derived()).coeffRef(index); |
377 |
return typename internal::evaluator<Derived>::type(derived()).coeffRef(index); |
373 |
} |
378 |
} |
374 |
|
379 |
|
375 |
/** \returns a reference to the coefficient at given index. |
380 |
/** \returns a reference to the coefficient at given index. |
376 |
* |
381 |
* |
377 |
* This method is allowed only for vector expressions, and for matrix expressions having the LinearAccessBit. |
382 |
* This method is allowed only for vector expressions, and for matrix expressions having the LinearAccessBit. |
378 |
* |
383 |
* |