aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen
diff options
context:
space:
mode:
authorGravatar Thomas Capricelli <orzel@freehackers.org>2010-05-22 19:17:04 +0200
committerGravatar Thomas Capricelli <orzel@freehackers.org>2010-05-22 19:17:04 +0200
commit76dd0e5314aa4978b908323d47c735eb50168a17 (patch)
treefcd52d85d7d70685b19836d844b062ef861f711b /Eigen
parent79e9e3f24c1b28a49aab62487cf7d58264b07502 (diff)
fix some warnings
Diffstat (limited to 'Eigen')
-rw-r--r--Eigen/src/Sparse/SparseLU.h6
-rw-r--r--Eigen/src/Sparse/SparseProduct.h9
-rw-r--r--Eigen/src/Sparse/SparseSelfAdjointView.h2
-rw-r--r--Eigen/src/Sparse/SparseUtil.h2
-rw-r--r--Eigen/src/Sparse/SparseVector.h2
5 files changed, 13 insertions, 8 deletions
diff --git a/Eigen/src/Sparse/SparseLU.h b/Eigen/src/Sparse/SparseLU.h
index 3fe9df1ef..0211b78e2 100644
--- a/Eigen/src/Sparse/SparseLU.h
+++ b/Eigen/src/Sparse/SparseLU.h
@@ -102,7 +102,7 @@ class SparseLU
void setOrderingMethod(int m)
{
- ei_assert(m&~OrderingMask == 0 && m!=0 && "invalid ordering method");
+ ei_assert( (m&~OrderingMask) == 0 && m!=0 && "invalid ordering method");
m_flags = m_flags&~OrderingMask | m&OrderingMask;
}
@@ -138,7 +138,7 @@ class SparseLU
* using the default algorithm.
*/
template<typename MatrixType, int Backend>
-void SparseLU<MatrixType,Backend>::compute(const MatrixType& a)
+void SparseLU<MatrixType,Backend>::compute(const MatrixType& )
{
ei_assert(false && "not implemented yet");
}
@@ -153,7 +153,7 @@ void SparseLU<MatrixType,Backend>::compute(const MatrixType& a)
*/
template<typename MatrixType, int Backend>
template<typename BDerived, typename XDerived>
-bool SparseLU<MatrixType,Backend>::solve(const MatrixBase<BDerived> &b, MatrixBase<XDerived>* x, const int transposed) const
+bool SparseLU<MatrixType,Backend>::solve(const MatrixBase<BDerived> &, MatrixBase<XDerived>* , const int ) const
{
ei_assert(false && "not implemented yet");
return false;
diff --git a/Eigen/src/Sparse/SparseProduct.h b/Eigen/src/Sparse/SparseProduct.h
index 4499e88be..078ac5f48 100644
--- a/Eigen/src/Sparse/SparseProduct.h
+++ b/Eigen/src/Sparse/SparseProduct.h
@@ -156,8 +156,8 @@ static void ei_sparse_product_impl2(const Lhs& lhs, const Rhs& rhs, ResultType&
float avgNnzPerRhsColumn = float(rhs.nonZeros())/float(cols);
float ratioRes = std::min(ratioLhs * avgNnzPerRhsColumn, 1.f);
- int t200 = rows/(log2(200)*1.39);
- int t = (rows*100)/139;
+// int t200 = rows/(log2(200)*1.39);
+// int t = (rows*100)/139;
res.resize(rows, cols);
res.reserve(int(ratioRes*rows*cols));
@@ -377,6 +377,11 @@ struct ei_sparse_product_selector2<Lhs,Rhs,ResultType,RowMajor,ColMajor,ColMajor
{
static void run(const Lhs& lhs, const Rhs& rhs, ResultType& res)
{
+ // prevent warnings until the code is fixed
+ (void) lhs;
+ (void) rhs;
+ (void) res;
+
// typedef SparseMatrix<typename ResultType::Scalar,RowMajor> RowMajorMatrix;
// RowMajorMatrix rhsRow = rhs;
// RowMajorMatrix resRow(res.rows(), res.cols());
diff --git a/Eigen/src/Sparse/SparseSelfAdjointView.h b/Eigen/src/Sparse/SparseSelfAdjointView.h
index 8496612d0..d47705337 100644
--- a/Eigen/src/Sparse/SparseSelfAdjointView.h
+++ b/Eigen/src/Sparse/SparseSelfAdjointView.h
@@ -214,7 +214,7 @@ class DenseTimeSparseSelfAdjointProduct
DenseTimeSparseSelfAdjointProduct(const Lhs& lhs, const Rhs& rhs) : Base(lhs,rhs)
{}
- template<typename Dest> void scaleAndAddTo(Dest& dest, Scalar alpha) const
+ template<typename Dest> void scaleAndAddTo(Dest& /*dest*/, Scalar /*alpha*/) const
{
// TODO
}
diff --git a/Eigen/src/Sparse/SparseUtil.h b/Eigen/src/Sparse/SparseUtil.h
index b051b6818..782690b26 100644
--- a/Eigen/src/Sparse/SparseUtil.h
+++ b/Eigen/src/Sparse/SparseUtil.h
@@ -144,7 +144,7 @@ const int InnerRandomAccessPattern = 0x2 | CoherentAccessPattern;
const int OuterRandomAccessPattern = 0x4 | CoherentAccessPattern;
const int RandomAccessPattern = 0x8 | OuterRandomAccessPattern | InnerRandomAccessPattern;
-template<typename T> class ei_eval<T,Sparse>
+template<typename T> struct ei_eval<T,Sparse>
{
typedef typename ei_traits<T>::Scalar _Scalar;
enum {
diff --git a/Eigen/src/Sparse/SparseVector.h b/Eigen/src/Sparse/SparseVector.h
index d328312d0..6806ab288 100644
--- a/Eigen/src/Sparse/SparseVector.h
+++ b/Eigen/src/Sparse/SparseVector.h
@@ -379,7 +379,7 @@ class SparseVector<Scalar,_Options>::InnerIterator
{}
template<unsigned int Added, unsigned int Removed>
- InnerIterator(const Flagged<SparseVector,Added,Removed>& vec, int outer)
+ InnerIterator(const Flagged<SparseVector,Added,Removed>& vec, int )
: m_data(vec._expression().m_data), m_id(0), m_end(m_data.size())
{}