changeset 58:11395e64852f

Replace include guards with #pragma once
author Jordi Gutiérrez Hermoso <jordigh@gmail.com>
date Sat, 15 May 2010 19:18:07 -0500
parents 3b19e979df45
children f8bd0fd20cc8
files src/include/bvp.hpp src/include/ddm.hpp src/include/diff_op.hpp src/include/error.hpp src/include/func.hpp src/include/interp_values.hpp src/include/interpolator.hpp src/include/linalg.hpp src/include/rbf.hpp src/include/utils.hpp src/include/vtkplot.hpp
diffstat 11 files changed, 22 insertions(+), 51 deletions(-) [+]
line wrap: on
line diff
--- a/src/include/bvp.hpp
+++ b/src/include/bvp.hpp
@@ -6,8 +6,7 @@
  *  classes declared in bvp.hpp
  */
 
-#ifndef __BVP_HPP__
-#define __BVP_HPP__
+#pramga once
 
 #include <map>
 #include <set>
@@ -217,6 +216,6 @@
   ///Give the interior diff_op.
   shared_ptr<const linear_diff_op2> get_linear_diff_op2() const;
 };
-}
 
-#endif //__BVP_HPP__
+}//namespace kwantix
+
--- a/src/include/ddm.hpp
+++ b/src/include/ddm.hpp
@@ -4,8 +4,7 @@
  *  \brief Implementations and instantiations of the functions and
  *  classes declared in ddm.hpp
  */
-#ifndef __DDM_HPP__
-#define __DDM_HPP__
+#pragma once
 
 #include <vector>
 #include <map>
@@ -196,7 +195,4 @@
  */
 void set_overlapper_info(set<shared_ptr<overlapping_domain> > 
                          domains);
-}
-
-#endif // __DDM_HPP__
-
+}//namsepace kwantix
--- a/src/include/diff_op.hpp
+++ b/src/include/diff_op.hpp
@@ -7,8 +7,7 @@
  *  classes declared in diff_op.hpp
  */
 
-#ifndef __DIFF_OP_HPP__
-#define __DIFF_OP_HPP__
+#pragma once
 
 #include "linalg.hpp"
 #include "func.hpp"
@@ -147,7 +146,5 @@
 public:
   double at(const realfunc &f, const point &p) const;
 };
-  
-}
 
-#endif //__DIFF_OP_HPP__
+}//namespace kwantix
--- a/src/include/error.hpp
+++ b/src/include/error.hpp
@@ -12,8 +12,7 @@
  *  classes declared in error.hpp
  */
 
-#ifndef __ERROR_HPP__
-#define __ERROR_HPP__
+#pragma once
 
 #include <gsl/gsl_errno.h>
 #include <string>
@@ -324,6 +323,5 @@
   indexOutOfRange(string r, string f, int l)  : 
     badArgument(r,f,l) {};
 };
-}
 
-#endif //__ERROR_HPP__
+}//namespace kwantix
--- a/src/include/func.hpp
+++ b/src/include/func.hpp
@@ -10,8 +10,7 @@
  *  \brief Implementations and instantiations of the functions and
  *  classes declared in func.hpp
  */
-#ifndef __FUNC_HPP__
-#define __FUNC_HPP__
+#pragma once
 
 #include "linalg.hpp"
 #include "error.hpp"
@@ -107,6 +106,5 @@
   /// The GSL function formed with the above data.
   static gsl_function* f;
 };
-}
 
-#endif //__FUNC_HPP__
+} //namespace kwantix
--- a/src/include/interp_values.hpp
+++ b/src/include/interp_values.hpp
@@ -1,5 +1,4 @@
-#ifndef __INTERP_VALUES_HPP__
-#define __INTERP_VALUES_HPP__
+#pragma once
 
 #include "linalg.hpp"
 #include <map>
@@ -161,6 +160,5 @@
 interp_values operator*(double a, const interp_values& v); 
 interp_values operator/(double a, const interp_values& v); 
 //@}
-}
 
-#endif //__INTERP_VALUES_HPP__
+}//namespace kwantix
--- a/src/include/interpolator.hpp
+++ b/src/include/interpolator.hpp
@@ -8,8 +8,7 @@
  *  \brief Implementations and instantiations of the functions and
  *  classes declared in interpolator.hpp
  */
-#ifndef __INTERPOLATOR_HPP__
-#define __INTERPOLATOR_HPP__
+#pragma once
 
 #include <vector>
 #include <map>
@@ -292,7 +291,4 @@
   return os;
 }
 
-  
-}
-
-#endif
+}//namespace kwnatix
--- a/src/include/linalg.hpp
+++ b/src/include/linalg.hpp
@@ -10,8 +10,7 @@
  *  classes declared in linalg.hpp
  */
 
-#ifndef __LINALG_HPP__
-#define __LINALG_HPP__
+#pragma once
 
 #include <gsl/gsl_matrix.h>
 #include <gsl/gsl_vector.h>
@@ -511,5 +510,4 @@
   }
 }
 
-}
-#endif //__LINALG_HPP__
+}//namespace kwantix
--- a/src/include/rbf.hpp
+++ b/src/include/rbf.hpp
@@ -5,8 +5,7 @@
  *  \brief Implementations and pinstantiations of the functions and
  *  classes declared in rbf.hpp
  */
-#ifndef __RBF_HPP__
-#define __RBF_HPP__
+#pragma once
 
 #include "linalg.hpp"
 #include "error.hpp"
@@ -221,5 +220,3 @@
 };
 
 }//namespace kwantix
-
-#endif // __RBF_HPP__ 
--- a/src/include/utils.hpp
+++ b/src/include/utils.hpp
@@ -6,8 +6,7 @@
  *  classes declared in utils.hpp
  */
 
-#ifndef __UTILS_HPP__ 
-#define __UTILS_HPP__
+#pragma once
 
 #include <string>
 #include <map>
@@ -44,6 +43,4 @@
 ///Outputs some information about generic exceptions.
 void show_exception(kwantix::error exc);
 
-}
-
-#endif
+}//namespace kwantix
--- a/src/include/vtkplot.hpp
+++ b/src/include/vtkplot.hpp
@@ -1,5 +1,4 @@
-#ifndef __VTKPLOTTING_HPP__
-#define __VTKPLOTTING_HPP__
+#pragma once
 
 #include <string>
 
@@ -81,6 +80,4 @@
   bool offscreen;
 };
 
-}
-
-#endif //__VTKPLOTTING_HPP__
+} //namespace kwantix