]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fix a test so it can run in C++03 mode. 2644/head
authorDavid Wells <wellsd2@rpi.edu>
Sat, 28 May 2016 18:10:30 +0000 (14:10 -0400)
committerDavid Wells <wellsd2@rpi.edu>
Sat, 28 May 2016 18:10:30 +0000 (14:10 -0400)
std::to_string is a C++11 addition.

tests/mpi/periodic_neighbor_01.cc

index 8241e0f5075834f9c3fb57073a988e0d5711d13a..b1ae7bcdbe2b0e57ca94ecd2d14faba32554eff8 100755 (executable)
@@ -84,6 +84,7 @@
  */
 
 #include "../tests.h"
+#include <deal.II/base/utilities.h>
 #include <deal.II/distributed/grid_refinement.h>
 #include <deal.II/distributed/tria.h>
 #include <deal.II/grid/grid_generator.h>
@@ -198,14 +199,14 @@ void periodicity_tests<dim>::write_grid()
   Grid1_Out.set_flags(svg_flags);
   if (dim == 2)
     {
-      std::ofstream Grid1_OutFile("Grid1" + std::to_string(refn_cycle) +
-                                  std::to_string(comm_rank) + ".svg");
+      std::ofstream Grid1_OutFile("Grid1" + dealii::Utilities::to_string(refn_cycle) +
+                                  dealii::Utilities::to_string(comm_rank) + ".svg");
       Grid1_Out.write_svg(the_grid, Grid1_OutFile);
     }
   else
     {
-      std::ofstream Grid1_OutFile("Grid1" + std::to_string(refn_cycle) +
-                                  std::to_string(comm_rank) + ".msh");
+      std::ofstream Grid1_OutFile("Grid1" + dealii::Utilities::to_string(refn_cycle) +
+                                  dealii::Utilities::to_string(comm_rank) + ".msh");
       Grid1_Out.write_msh(the_grid, Grid1_OutFile);
     }
 }

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.