From 457f2593ff321f61b7632b5ae17b317101beaa2a Mon Sep 17 00:00:00 2001 From: Marc Fehling Date: Fri, 25 Feb 2022 12:12:12 -0700 Subject: [PATCH] cell_weight: not implemented for partition_zorder --- source/grid/grid_tools.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/source/grid/grid_tools.cc b/source/grid/grid_tools.cc index 9cd09727d8..361721e687 100644 --- a/source/grid/grid_tools.cc +++ b/source/grid/grid_tools.cc @@ -4028,6 +4028,7 @@ namespace GridTools "are already partitioned implicitly and can not be " "partitioned again explicitly.")); Assert(n_partitions > 0, ExcInvalidNumberOfPartitions(n_partitions)); + Assert(triangulation.signals.cell_weight.empty(), ExcNotImplemented()); // signal that partitioning is going to happen triangulation.signals.pre_partition(); @@ -4128,10 +4129,7 @@ namespace GridTools unsigned int n_levels = triangulation.n_levels(); for (int lvl = n_levels - 1; lvl >= 0; --lvl) { - typename Triangulation::cell_iterator - cell = triangulation.begin(lvl), - endc = triangulation.end(lvl); - for (; cell != endc; ++cell) + for (const auto &cell : triangulation.cell_iterators_on_level(lvl)) { if (cell->is_active()) cell->set_level_subdomain_id(cell->subdomain_id()); -- 2.39.5