From 1f24a6fbad52500e1e60f126dc99c0f5753e3149 Mon Sep 17 00:00:00 2001
From: Elias Pipping <elias.pipping@fu-berlin.de>
Date: Sun, 31 Mar 2013 00:03:26 +0000
Subject: [PATCH] Fix warnings: Unused typedefs inside functions

[[Imported from SVN: r8384]]
---
 dune/solvers/common/genericvectortools.hh            |  4 ----
 dune/solvers/common/staticmatrixtools.hh             |  4 ----
 dune/solvers/iterationsteps/truncatedblockgsstep.hh  |  2 --
 .../transferoperators/genericmultigridtransfer.hh    | 12 ------------
 4 files changed, 22 deletions(-)

diff --git a/dune/solvers/common/genericvectortools.hh b/dune/solvers/common/genericvectortools.hh
index c4bb6df2..29b95b24 100644
--- a/dune/solvers/common/genericvectortools.hh
+++ b/dune/solvers/common/genericvectortools.hh
@@ -277,8 +277,6 @@ struct GenericMatrix
 //        dune_static_assert(BitVectorTypeR.size()==n and BitVectorTypeC.size()==m,"BitVector length doesn't match matrix size.");
         assert(trows.size()==n and tcols.size()==m);
 
-        typedef typename Dune::FieldMatrix<field_type,n,m> MatrixType;
-
         for(size_t row=0; row<n; ++row)
         {
             if (trows[row])
@@ -300,8 +298,6 @@ struct GenericMatrix
     template <class field_type, int n, class BitVectorType>
     static void truncate(Dune::DiagonalMatrix<field_type,n>& mat, const BitVectorType& trows, const BitVectorType& tcols, bool setTruncatedDiagonalOne)
     {
-        typedef typename Dune::DiagonalMatrix<field_type,n> MatrixType;
-
         for(size_t row=0; row<n; ++row)
         {
             if (trows[row])
diff --git a/dune/solvers/common/staticmatrixtools.hh b/dune/solvers/common/staticmatrixtools.hh
index d21ff418..d2f132c8 100644
--- a/dune/solvers/common/staticmatrixtools.hh
+++ b/dune/solvers/common/staticmatrixtools.hh
@@ -280,8 +280,6 @@ class StaticMatrix
         template<class MatrixBlockA, class MatrixB, class MatrixT>
         static void transformMatrix(Dune::BCRSMatrix<MatrixBlockA>& A, const MatrixT& X, const MatrixB& B, const MatrixT& Y)
         {
-            typedef typename Dune::BCRSMatrix<MatrixBlockA> MatrixA;
-
             transformMatrixPattern(A, X, B, Y);
             A = 0.0;
             for (int k=0; k<B.N(); ++k)
@@ -315,8 +313,6 @@ class StaticMatrix
         template<class MatrixBlockA, class MatrixB, class MatrixT>
         static void transformMatrixPattern(Dune::BCRSMatrix<MatrixBlockA>& A, const MatrixT& X, const MatrixB& B, const MatrixT& Y)
         {
-            typedef typename Dune::BCRSMatrix<MatrixBlockA> MatrixA;
-
             Dune::MatrixIndexSet indices(X.M(), Y.M());
             for (int k=0; k<B.N(); ++k)
             {
diff --git a/dune/solvers/iterationsteps/truncatedblockgsstep.hh b/dune/solvers/iterationsteps/truncatedblockgsstep.hh
index dae872c2..d68db41a 100644
--- a/dune/solvers/iterationsteps/truncatedblockgsstep.hh
+++ b/dune/solvers/iterationsteps/truncatedblockgsstep.hh
@@ -95,7 +95,6 @@ struct RecursiveGSStep<1>
     static void apply(const MType& mat, const VType& rhs, const BVType& ignore, VType& x)
     {
         typedef typename MType::block_type MBlock;
-        typedef typename VType::block_type VBlock;
 
         for (size_t i=0; i<mat.N(); ++i)
         {
@@ -162,7 +161,6 @@ public:
     virtual void iterate()
     {
         typedef typename SparseMatrixType::row_type::ConstIterator SparseMatrixColumnIterator;
-        typedef typename LowRankMatrixType::LowRankFactorType::row_type::ConstIterator LowRankFactorColumnIterator;
 
         const MatrixType& mat = *this->mat_;
         const SparseMatrixType& sparse_mat = mat.sparseMatrix();
diff --git a/dune/solvers/transferoperators/genericmultigridtransfer.hh b/dune/solvers/transferoperators/genericmultigridtransfer.hh
index c1fd17e8..c1cedbc1 100644
--- a/dune/solvers/transferoperators/genericmultigridtransfer.hh
+++ b/dune/solvers/transferoperators/genericmultigridtransfer.hh
@@ -233,9 +233,6 @@ public:
 
         t.resize(matrix.N());
 
-        typedef typename DiscFuncType::Iterator      Iterator;
-        typedef typename DiscFuncType::ConstIterator ConstIterator;
-
         typedef typename TransferOperatorType::row_type RowType;
         typedef typename RowType::ConstIterator ColumnIterator;
 
@@ -267,9 +264,6 @@ public:
 
         t.resize(matrix.N()*virtualBlockSize);
 
-        typedef typename DiscFuncType::Iterator      Iterator;
-        typedef typename DiscFuncType::ConstIterator ConstIterator;
-
         typedef typename TransferOperatorType::row_type RowType;
         typedef typename RowType::ConstIterator ColumnIterator;
 
@@ -303,9 +297,6 @@ public:
         t.resize(matrix.M());
         t = 0;
 
-        typedef typename DiscFuncType::Iterator      Iterator;
-        typedef typename DiscFuncType::ConstIterator ConstIterator;
-
         typedef typename TransferOperatorType::row_type RowType;
         typedef typename RowType::ConstIterator ColumnIterator;
 
@@ -336,9 +327,6 @@ public:
         t.resize(matrix.M()*virtualBlockSize);
         t = 0;
 
-        typedef typename DiscFuncType::Iterator      Iterator;
-        typedef typename DiscFuncType::ConstIterator ConstIterator;
-
         typedef typename TransferOperatorType::row_type RowType;
         typedef typename RowType::ConstIterator ColumnIterator;
 
-- 
GitLab