]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Use the information provided by the numeric_limits class if available.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Fri, 25 Jan 2002 12:21:54 +0000 (12:21 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Fri, 25 Jan 2002 12:21:54 +0000 (12:21 +0000)
git-svn-id: https://svn.dealii.org/trunk@5406 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/base/source/parameter_handler.cc

index bd54a910e448ede0b7bb598fc22092490b1fcc3c..aa60ca9074cfe66daf9d7df66d0b4345505756a3 100644 (file)
@@ -54,6 +54,9 @@ namespace Patterns
   
 
 
+  const int Integer::min_int_value;
+  const int Integer::max_int_value;
+  
 
   Integer::Integer (const int lower_bound,
                    const int upper_bound) :
@@ -124,8 +127,22 @@ namespace Patterns
 
 
 
-  Double::Double (const int lower_bound,
-                 const int upper_bound) :
+  const double Double::min_double_value =
+#ifdef HAVE_STD_NUMERIC_LIMITS
+          std::numeric_limits<double>::min();
+#else
+          1;
+#endif
+  
+  const double Double::max_double_value =
+#ifdef HAVE_STD_NUMERIC_LIMITS
+          std::numeric_limits<double>::max();
+#else
+          0;
+#endif
+  
+  Double::Double (const double lower_bound,
+                 const double upper_bound) :
                  lower_bound (lower_bound),
                  upper_bound (upper_bound)
   {};

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.