]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fix compiler warning 13914/head
authorNiklas Wik <niiklaswiik@gmail.com>
Mon, 6 Jun 2022 11:33:47 +0000 (13:33 +0200)
committerNiklas Wik <niiklaswiik@gmail.com>
Tue, 7 Jun 2022 08:51:43 +0000 (10:51 +0200)
include/deal.II/matrix_free/evaluation_kernels.h

index ff05bbc5a0b6e3122738029c404ceede7e3f97a3..dc276f9e45dd6448d0b303faeafb6ebb195274c7 100644 (file)
@@ -3697,6 +3697,15 @@ namespace internal
       const unsigned int                            face_no,
       const MatrixFreeFunctions::ShapeInfo<Number> &shape_info)
     {
+      if (dim == 1)
+        {
+          // This should never happen since the FE_RaviartThomasNodal is not
+          // defined for dim = 1. It prevents compiler warnings of infinite
+          // recursion.
+          Assert(false, ExcInternalError());
+          return;
+        }
+
       bool increase_max_der = false;
       if ((flag & EvaluationFlags::hessians && max_derivative < 2) ||
           (flag & EvaluationFlags::gradients && max_derivative < 1))

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.