]> https://gitweb.dealii.org/ - dealii.git/commitdiff
GridTools::exchange_cell_data_to_ghosts replace static_cast by dynamic_cast 9909/head
authorPeter Munch <peterrmuench@gmail.com>
Thu, 16 Apr 2020 15:08:12 +0000 (17:08 +0200)
committerPeter Munch <peterrmuench@gmail.com>
Thu, 16 Apr 2020 15:08:12 +0000 (17:08 +0200)
include/deal.II/grid/grid_tools.h

index 2794c312703a59fa8a98402582b989d5234962e0..1729391102b894199fe3d7e40d6f436e318e0e8f 100644 (file)
@@ -3898,8 +3898,9 @@ namespace GridTools
 #    else
     constexpr int dim      = MeshType::dimension;
     constexpr int spacedim = MeshType::space_dimension;
-    auto tria = static_cast<const parallel::TriangulationBase<dim, spacedim> *>(
-      &mesh.get_triangulation());
+    auto          tria =
+      dynamic_cast<const parallel::TriangulationBase<dim, spacedim> *>(
+        &mesh.get_triangulation());
     Assert(
       tria != nullptr,
       ExcMessage(

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.