]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Avoid warning 'unsigned expression < 0 always false' by using int 11016/head
authorMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Wed, 7 Oct 2020 12:45:37 +0000 (14:45 +0200)
committerMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Wed, 7 Oct 2020 12:45:37 +0000 (14:45 +0200)
include/deal.II/matrix_free/mapping_info.templates.h

index c7561253db9861b98e99df9970629bf1acb85dca..58255da351018cd3ef70f5c157b35982fd32ca63 100644 (file)
@@ -71,7 +71,7 @@ namespace internal
       for (unsigned int i = 0; i < n_q_points; ++i)
         quadrature_weights[i] = quadrature.weight(i);
 
-      for (unsigned int d = 0; d < structdim; ++d)
+      for (int d = 0; d < structdim; ++d)
         {
           tensor_quadrature_weights[d].resize(quadrature_1d.size());
           for (unsigned int i = 0; i < quadrature_1d.size(); ++i)
@@ -120,7 +120,7 @@ namespace internal
       std::size_t memory = sizeof(this) + quadrature.memory_consumption() +
                            quadrature_weights.memory_consumption() +
                            face_orientations.memory_consumption();
-      for (unsigned int d = 0; d < structdim; ++d)
+      for (int d = 0; d < structdim; ++d)
         memory += tensor_quadrature_weights[d].memory_consumption();
       return memory;
     }

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.