]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Make a few functions inline.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Tue, 20 Dec 2005 05:19:26 +0000 (05:19 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Tue, 20 Dec 2005 05:19:26 +0000 (05:19 +0000)
git-svn-id: https://svn.dealii.org/trunk@11890 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/dofs/hp_dof_accessor.cc

index 3d1c04792c4b57b588093f443d98e389e8f99b3d..47052bfd77620633adde894e871c6836ac960f35 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2003 by the deal.II authors
+//    Copyright (C) 2003, 2005 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -84,8 +84,8 @@ void DoFObjectAccessor<1, 1, hpDoFHandler>::set_dof_index (const unsigned int i,
   Assert (i<this->get_fe().dofs_per_line,
          ExcIndexRange (i, 0, this->get_fe().dofs_per_line));
 
-  unsigned int offset = this->dof_handler->levels[this->present_level]
-      ->dof_line_index_offset[this->present_index];
+  const unsigned int offset = this->dof_handler->levels[this->present_level]
+                              ->dof_line_index_offset[this->present_index];
   this->dof_handler->levels[this->present_level]
       ->line_dofs[offset+i] = index;
 }
@@ -110,8 +110,8 @@ void DoFObjectAccessor<1, 2, hpDoFHandler>::set_dof_index (const unsigned int i,
 // on a line between to cells. Hence we have to differentiate between these two cases.
 // Unfortunately, this requires more information then available now.
 
-  unsigned int offset = this->dof_handler->levels[this->present_level]
-      ->dof_line_index_offset[this->present_index];
+  const unsigned int offset = this->dof_handler->levels[this->present_level]
+                              ->dof_line_index_offset[this->present_index];
   this->dof_handler->levels[this->present_level]
       ->line_dofs[offset+i] = index;
 }
@@ -132,8 +132,8 @@ void DoFObjectAccessor<1, 3, hpDoFHandler>::set_dof_index (const unsigned int i,
   Assert (i<this->get_fe().dofs_per_line,
          ExcIndexRange (i, 0, this->get_fe().dofs_per_line));
 
-  unsigned int offset = this->dof_handler->levels[this->present_level]
-      ->dof_line_index_offset[this->present_index];
+  const unsigned int offset = this->dof_handler->levels[this->present_level]
+                              ->dof_line_index_offset[this->present_index];
   this->dof_handler->levels[this->present_level]
       ->line_dofs[offset+i] = index;
 }
@@ -157,8 +157,8 @@ void DoFObjectAccessor<2, 2, hpDoFHandler>::set_dof_index (const unsigned int i,
   Assert (i<this->get_fe().dofs_per_quad,
          ExcIndexRange (i, 0, this->get_fe().dofs_per_quad));
 
-  unsigned int offset = this->dof_handler->levels[this->present_level]
-      ->dof_quad_index_offset[this->present_index];
+  const unsigned int offset = this->dof_handler->levels[this->present_level]
+                              ->dof_quad_index_offset[this->present_index];
   this->dof_handler->levels[this->present_level]
       ->quad_dofs[offset+i] = index;
 }
@@ -179,8 +179,8 @@ void DoFObjectAccessor<2, 3, hpDoFHandler>::set_dof_index (const unsigned int i,
   Assert (i<this->get_fe().dofs_per_quad,
          ExcIndexRange (i, 0, this->get_fe().dofs_per_quad));
 
-  unsigned int offset = this->dof_handler->levels[this->present_level]
-      ->dof_quad_index_offset[this->present_index];
+  const unsigned int offset = this->dof_handler->levels[this->present_level]
+                              ->dof_quad_index_offset[this->present_index];
   this->dof_handler->levels[this->present_level]
       ->quad_dofs[offset+i] = index;
 }
@@ -203,8 +203,8 @@ void DoFObjectAccessor<3, 3, hpDoFHandler>::set_dof_index (const unsigned int i,
   Assert (i<this->get_fe().dofs_per_hex,
          ExcIndexRange (i, 0, this->get_fe().dofs_per_hex));
 
-  unsigned int offset = this->dof_handler->levels[this->present_level]
-      ->dof_hex_index_offset[this->present_index];
+  const unsigned int offset = this->dof_handler->levels[this->present_level]
+                              ->dof_hex_index_offset[this->present_index];
   this->dof_handler->levels[this->present_level]
       ->hex_dofs[offset+i] = 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.