diff options
author | Gael Guennebaud <g.gael@free.fr> | 2012-06-22 16:32:45 +0200 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2012-06-22 16:32:45 +0200 |
commit | 62c504e7bf62460b4c33f479abea789d18a9ad89 (patch) | |
tree | 7dc23d72c46251b0c7869b183a332c24e4aaaf75 /Eigen/src/Core/Swap.h | |
parent | 5fae6c7848944df9ed3389b5714362e29f531b91 (diff) |
fix most of the shadow warnings in Core/*.h
Diffstat (limited to 'Eigen/src/Core/Swap.h')
-rw-r--r-- | Eigen/src/Core/Swap.h | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/Eigen/src/Core/Swap.h b/Eigen/src/Core/Swap.h index deb1d2831..02c5efe51 100644 --- a/Eigen/src/Core/Swap.h +++ b/Eigen/src/Core/Swap.h @@ -64,9 +64,9 @@ template<typename ExpressionType> class SwapWrapper inline ScalarWithConstIfNotLvalue* data() { return m_expression.data(); } inline const Scalar* data() const { return m_expression.data(); } - inline Scalar& coeffRef(Index row, Index col) + inline Scalar& coeffRef(Index rowId, Index colId) { - return m_expression.const_cast_derived().coeffRef(row, col); + return m_expression.const_cast_derived().coeffRef(rowId, colId); } inline Scalar& coeffRef(Index index) @@ -74,9 +74,9 @@ template<typename ExpressionType> class SwapWrapper return m_expression.const_cast_derived().coeffRef(index); } - inline Scalar& coeffRef(Index row, Index col) const + inline Scalar& coeffRef(Index rowId, Index colId) const { - return m_expression.coeffRef(row, col); + return m_expression.coeffRef(rowId, colId); } inline Scalar& coeffRef(Index index) const @@ -85,14 +85,14 @@ template<typename ExpressionType> class SwapWrapper } template<typename OtherDerived> - void copyCoeff(Index row, Index col, const DenseBase<OtherDerived>& other) + void copyCoeff(Index rowId, Index colId, const DenseBase<OtherDerived>& other) { OtherDerived& _other = other.const_cast_derived(); - eigen_internal_assert(row >= 0 && row < rows() - && col >= 0 && col < cols()); - Scalar tmp = m_expression.coeff(row, col); - m_expression.coeffRef(row, col) = _other.coeff(row, col); - _other.coeffRef(row, col) = tmp; + eigen_internal_assert(rowId >= 0 && rowId < rows() + && colId >= 0 && colId < cols()); + Scalar tmp = m_expression.coeff(rowId, colId); + m_expression.coeffRef(rowId, colId) = _other.coeff(rowId, colId); + _other.coeffRef(rowId, colId) = tmp; } template<typename OtherDerived> @@ -106,16 +106,16 @@ template<typename ExpressionType> class SwapWrapper } template<typename OtherDerived, int StoreMode, int LoadMode> - void copyPacket(Index row, Index col, const DenseBase<OtherDerived>& other) + void copyPacket(Index rowId, Index colId, const DenseBase<OtherDerived>& other) { OtherDerived& _other = other.const_cast_derived(); - eigen_internal_assert(row >= 0 && row < rows() - && col >= 0 && col < cols()); - Packet tmp = m_expression.template packet<StoreMode>(row, col); - m_expression.template writePacket<StoreMode>(row, col, - _other.template packet<LoadMode>(row, col) + eigen_internal_assert(rowId >= 0 && rowId < rows() + && colId >= 0 && colId < cols()); + Packet tmp = m_expression.template packet<StoreMode>(rowId, colId); + m_expression.template writePacket<StoreMode>(rowId, colId, + _other.template packet<LoadMode>(rowId, colId) ); - _other.template writePacket<LoadMode>(row, col, tmp); + _other.template writePacket<LoadMode>(rowId, colId, tmp); } template<typename OtherDerived, int StoreMode, int LoadMode> |