]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Fix several long long warnings
authorkainan.wang <kainan.wang@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 7 Apr 2013 19:16:32 +0000 (19:16 +0000)
committerkainan.wang <kainan.wang@0785d39b-7218-0410-832d-ea1e28bc413d>
Sun, 7 Apr 2013 19:16:32 +0000 (19:16 +0000)
git-svn-id: https://svn.dealii.org/branches/branch_bigger_global_dof_indices_4@29214 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/include/deal.II/base/index_set.h
deal.II/include/deal.II/base/partitioner.h
deal.II/include/deal.II/dofs/block_info.h
deal.II/include/deal.II/lac/constraint_matrix.h
deal.II/include/deal.II/lac/sparsity_pattern.h

index ef1c16bb184710dfd116b369dc5bce74c6b74c26..ba0baba9092d5b0c81f463e1e52a4f2c5b045561 100644 (file)
@@ -15,7 +15,6 @@
 #include <deal.II/base/config.h>
 #include <deal.II/base/utilities.h>
 #include <deal.II/base/exceptions.h>
-
 #include <vector>
 #include <algorithm>
 
@@ -172,7 +171,7 @@ public:
    * a member of this index set, i.e. if
    * is_element(global_index) is false.
    */
-  unsigned int index_within_set (const types::global_dof_index global_index) const;
+  types::global_dof_index index_within_set (const types::global_dof_index global_index) const;
 
   /**
    * Each index set can be
@@ -918,7 +917,7 @@ IndexSet::nth_index_in_set (const unsigned int n) const
 
 
 inline
-unsigned int
+types::global_dof_index
 IndexSet::index_within_set (const types::global_dof_index n) const
 {
   // to make this call thread-safe, compress()
index 353ac2d5acd11c524fecd1cb1abdecc7f750ad3d..d02546a8af770ffaadabc85183202c0a219c37d0 100644 (file)
@@ -448,7 +448,7 @@ namespace Utilities
         return static_cast<unsigned int>(global_index - local_range_data.first);
       else if (is_ghost_entry (global_index))
         return (local_size() +
-                ghost_indices_data.index_within_set (global_index));
+                static_cast<unsigned int>(ghost_indices_data.index_within_set (global_index)));
       else
         // should only end up here in
         // optimized mode, when we use this
index ccd162ac0339a9d8d03c9a5bfc9ee7eade133943..3a922d192d7a11e8afbfda7ac3bbb42616264db3 100644 (file)
@@ -261,7 +261,7 @@ BlockInfo::level (const unsigned int l) const
 inline
 types::global_dof_index BlockInfo::renumber (const unsigned int i) const
 {
-  AssertIndexRange(i, local_renumbering.size());
+  AssertIndexRange(i, static_cast<unsigned int>(local_renumbering.size()));
   return local_renumbering[i];
 }
 
index cbd11d0ce640eb6c5112f95c372f34e22fdaaced..ec12f55c9466895069b34bdcbb764f68d0c181e0 100644 (file)
@@ -1465,7 +1465,7 @@ public:
    * @ingroup Exceptions
    */
   DeclException4 (ExcEntryAlreadyExists,
-                  int, int, double, double,
+                  size_type, size_type, double, double,
                   << "The entry for the indices " << arg1 << " and "
                   << arg2 << " already exists, but the values "
                   << arg3 << " (old) and " << arg4 << " (new) differ "
@@ -1486,7 +1486,7 @@ public:
    * @ingroup Exceptions
    */
   DeclException1 (ExcDoFIsConstrainedFromBothObjects,
-                  int,
+                  size_type,
                   << "Degree of freedom " << arg1
                   << " is constrained from both object in a merge operation.");
   /**
@@ -1495,7 +1495,7 @@ public:
    * @ingroup Exceptions
    */
   DeclException1 (ExcDoFIsConstrainedToConstrainedDoF,
-                  int,
+                  size_type,
                   << "In the given argument a degree of freedom is constrained "
                   << "to another DoF with number " << arg1
                   << ", which however is constrained by this object. This is not"
@@ -1506,7 +1506,7 @@ public:
    * @ingroup Exceptions
    */
   DeclException1 (ExcRowNotStoredHere,
-                  int,
+                  size_type,
                   << "The index set given to this constraint matrix indicates "
                   << "constraints for degree of freedom " << arg1
                   << " should not be stored by this object, but a constraint "
index 0d0daa7930251ed2739de72307f1dca7f24a2719..aad75b9c4682fd6453215ecd278e5850091cf556 100644 (file)
@@ -1670,7 +1670,7 @@ inline
 SparsityPattern::iterator
 SparsityPattern::begin (const size_type r) const
 {
-  Assert (r<n_rows(), ExcIndexRange(r,0,n_rows()));
+  Assert (r<n_rows(), ExcIndexRangeType<size_type>(r,0,n_rows()));
 
   return iterator(this, rowstart[r]);
 }
@@ -1681,7 +1681,7 @@ inline
 SparsityPattern::iterator
 SparsityPattern::end (const size_type r) const
 {
-  Assert (r<n_rows(), ExcIndexRange(r,0,n_rows()));
+  Assert (r<n_rows(), ExcIndexRangeType<size_type>(r,0,n_rows()));
 
   return iterator(this, rowstart[r+1]);
 }
@@ -1692,7 +1692,7 @@ inline
 SparsityPattern::row_iterator
 SparsityPattern::row_begin (const size_type r) const
 {
-  Assert (r<n_rows(), ExcIndexRange(r,0,n_rows()));
+  Assert (r<n_rows(), ExcIndexRangeType<size_type>(r,0,n_rows()));
   return &colnums[rowstart[r]];
 }
 
@@ -1702,7 +1702,7 @@ inline
 SparsityPattern::row_iterator
 SparsityPattern::row_end (const size_type r) const
 {
-  Assert (r<n_rows(), ExcIndexRange(r,0,n_rows()));
+  Assert (r<n_rows(), ExcIndexRangeType<size_type>(r,0,n_rows()));
   return &colnums[rowstart[r+1]];
 }
 
@@ -1769,7 +1769,7 @@ inline
 SparsityPattern::size_type 
 SparsityPattern::row_length (const size_type row) const
 {
-  Assert(row<rows, ExcIndexRange(row,0,rows));
+  Assert(row<rows, ExcIndexRangeType<size_type>(row,0,rows));
   return rowstart[row+1]-rowstart[row];
 }
 
@@ -1780,8 +1780,8 @@ SparsityPattern::size_type
 SparsityPattern::column_number (const size_type row,
                                 const size_type index) const
 {
-  Assert(row<rows, ExcIndexRange(row,0,rows));
-  Assert(index<row_length(row), ExcIndexRange(index,0,row_length(row)));
+  Assert(row<rows, ExcIndexRangeType<size_type>(row,0,rows));
+  Assert(index<row_length(row), ExcIndexRangeType<size_type>(index,0,row_length(row)));
 
   return colnums[rowstart[row]+index];
 }

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.