From 0a520888da75a0d1862b47fc1145071d1907dc96 Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Fri, 12 May 2023 13:38:40 -0400 Subject: [PATCH] Fix warnings with gcc-13.1 --- include/deal.II/matrix_free/fe_evaluation.h | 4 +++- source/grid/grid_generator.cc | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/include/deal.II/matrix_free/fe_evaluation.h b/include/deal.II/matrix_free/fe_evaluation.h index 2af88182be..077067d7a6 100644 --- a/include/deal.II/matrix_free/fe_evaluation.h +++ b/include/deal.II/matrix_free/fe_evaluation.h @@ -3871,7 +3871,9 @@ FEEvaluationBase:: VectorizedArrayType::size()> vector_ptrs = {}; - for (unsigned int v = 0; v < n_filled_lanes; ++v) + const auto upper_bound = + std::min(n_filled_lanes, VectorizedArrayType::size()); + for (unsigned int v = 0; v < upper_bound; ++v) { if (mask[v] == false) { diff --git a/source/grid/grid_generator.cc b/source/grid/grid_generator.cc index 23dad9ea3e..24f41c2907 100644 --- a/source/grid/grid_generator.cc +++ b/source/grid/grid_generator.cc @@ -6644,7 +6644,7 @@ namespace GridGenerator else if (structdim == 2) { // rotate the vertex numbers so that the lowest one is first - std::array renumbering; + std::array renumbering{}; std::copy(std::begin(cell_data.vertices), std::end(cell_data.vertices), renumbering.begin()); -- 2.39.5