]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Bugfix: Fix type ambiguity for two calls to std::min
authorMatthias Maier <tamiko@43-1.org>
Tue, 1 Sep 2015 00:23:06 +0000 (19:23 -0500)
committerMatthias Maier <tamiko@43-1.org>
Mon, 7 Sep 2015 18:27:20 +0000 (13:27 -0500)
source/grid/grid_tools.cc

index d6eec4e0927f6f56da6ee962b933b2fe249eb22b..96394ba5844c2cb4c932e912f6ba96ccb0298923 100644 (file)
@@ -2397,9 +2397,10 @@ next_cell:
         for (unsigned int c=0; c<object->n_children(); ++c)
           for (unsigned int i=0; i<GeometryInfo<structdim>::vertices_per_cell; ++i)
             for (unsigned int j=0; j<GeometryInfo<structdim>::vertices_per_cell; ++j)
-              old_min_product = std::min (old_min_product,
-                                          child_alternating_forms[c][i] *
-                                          parent_alternating_forms[j]);
+              old_min_product =
+                std::min<double> (old_min_product,
+                                  child_alternating_forms[c][i] *
+                                  parent_alternating_forms[j]);
 
         // for the new minimum value,
         // replace mid-object
@@ -2419,9 +2420,10 @@ next_cell:
         for (unsigned int c=0; c<object->n_children(); ++c)
           for (unsigned int i=0; i<GeometryInfo<structdim>::vertices_per_cell; ++i)
             for (unsigned int j=0; j<GeometryInfo<structdim>::vertices_per_cell; ++j)
-              new_min_product = std::min (new_min_product,
-                                          child_alternating_forms[c][i] *
-                                          parent_alternating_forms[j]);
+              new_min_product =
+                std::min<double> (new_min_product,
+                                  child_alternating_forms[c][i] *
+                                  parent_alternating_forms[j]);
 
         // if new minimum value is
         // better than before, then set the

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.