]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
fix some size_type errors in the petsc wrappers
authorheister <heister@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 5 Mar 2013 18:42:53 +0000 (18:42 +0000)
committerheister <heister@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 5 Mar 2013 18:42:53 +0000 (18:42 +0000)
git-svn-id: https://svn.dealii.org/branches/branch_bigger_global_dof_indices_4@28740 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/include/deal.II/lac/petsc_matrix_base.h
deal.II/include/deal.II/lac/petsc_parallel_block_sparse_matrix.h
deal.II/include/deal.II/lac/petsc_vector_base.h

index e6042bcfd59ea9bf2bf630441dc478c1e73faac9..f3c7f5200d711b2b88d178552c3f6e2326176d61 100644 (file)
@@ -64,6 +64,11 @@ namespace PETScWrappers
       class Accessor
       {
       public:
+      /**
+       * Declare type for container size.
+       */
+      typedef types::global_dof_index size_type;
+         
         /**
          * Constructor. Since we use
          * accessors only for read
@@ -183,7 +188,7 @@ namespace PETScWrappers
        * Declare type for container size.
        */
       typedef types::global_dof_index size_type;
-
+       
       /**
        * Constructor. Create an iterator
        * into the matrix @p matrix for the
@@ -296,6 +301,11 @@ namespace PETScWrappers
      * class.
      */
     typedef MatrixIterators::const_iterator const_iterator;
+      
+      /**
+       * Declare type for container size.
+       */
+      typedef types::global_dof_index size_type;
 
     /**
      * Declare a typedef in analogy to all
@@ -1337,7 +1347,7 @@ namespace PETScWrappers
 
 
     inline
-    size_type 
+    const_iterator::Accessor::size_type 
     const_iterator::Accessor::row() const
     {
       Assert (a_row < matrix->m(), ExcBeyondEndOfMatrix());
@@ -1346,7 +1356,7 @@ namespace PETScWrappers
 
 
     inline
-    size_type 
+    const_iterator::Accessor::size_type 
     const_iterator::Accessor::column() const
     {
       Assert (a_row < matrix->m(), ExcBeyondEndOfMatrix());
@@ -1355,7 +1365,7 @@ namespace PETScWrappers
 
 
     inline
-    size_type 
+    const_iterator::Accessor::size_type 
     const_iterator::Accessor::index() const
     {
       Assert (a_row < matrix->m(), ExcBeyondEndOfMatrix());
index 4e50f1735e52a01caa77ed09d43b03fa13b2448c..2e61b8918757d210c9eb9b015ddf2e8e61e2cbb5 100644 (file)
@@ -62,11 +62,6 @@ namespace PETScWrappers
     class BlockSparseMatrix : public BlockMatrixBase<SparseMatrix>
     {
     public:
-      /**
-       * Declare type for container size.
-       */
-      typedef types::global_dof_index size_type;
-
       /**
        * Typedef the base class for simpler
        * access to its own typedefs.
index e3cc5e4ec6457ad5636a298ad988ca4589297759..2e00dc1c060b81af7070d4d38dcad601f1657b47 100644 (file)
@@ -77,7 +77,13 @@ namespace PETScWrappers
      */
     class VectorReference
     {
-    private:
+    public:
+      /**
+       * Declare type for container size.
+       */
+      typedef types::global_dof_index size_type;
+
+      private:
       /**
        * Constructor. It is made private so
        * as to only allow the actual vector
@@ -86,12 +92,9 @@ namespace PETScWrappers
       VectorReference (const VectorBase &vector,
                        const size_type   index);
 
-    public:
-      /**
-       * Declare type for container size.
-       */
-      typedef types::global_dof_index size_type;
 
+      public:
+       
       /**
        * This looks like a copy operator,
        * but does something different than

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.