From: Wolfgang Bangerth Date: Fri, 30 Dec 2022 22:25:30 +0000 (-0700) Subject: Move the update of a variable out of if-else branches. X-Git-Tag: v9.5.0-rc1~690^2~5 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b87bb5b03571b5c11c646286af8e3d0bb976a717;p=dealii.git Move the update of a variable out of if-else branches. --- diff --git a/source/base/data_out_base.cc b/source/base/data_out_base.cc index 9a460e5198..c14c91179d 100644 --- a/source/base/data_out_base.cc +++ b/source/base/data_out_base.cc @@ -6070,11 +6070,6 @@ namespace DataOutBase default: Assert(false, ExcNotImplemented()); } - - // Finally update the number of the first vertex of this - // patch - first_vertex_of_patch += - Utilities::fixed_power(n_subdivisions + 1); } else // use higher-order output { @@ -6174,11 +6169,12 @@ namespace DataOutBase o << '\t' << first_vertex_of_patch + c; o << '\n'; } - - // Finally update the number of the first vertex of this - // patch - first_vertex_of_patch += Utilities::fixed_power(n); } + + // Finally update the number of the first vertex of this + // patch + first_vertex_of_patch += + Utilities::fixed_power(patch.n_subdivisions + 1); } }