From: David Wells Date: Sat, 11 Apr 2015 12:47:02 +0000 (-0400) Subject: Get rid of named temporaries for asserts. X-Git-Tag: v8.3.0-rc1~278^2~5 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c2ad0bfa63b173bab8abd6c97ec7b49a8da82d43;p=dealii.git Get rid of named temporaries for asserts. This also avoids writing a lot of (void)s. --- diff --git a/source/grid/tria_boundary_lib.cc b/source/grid/tria_boundary_lib.cc index 4ad712eccc..a2faeb723a 100644 --- a/source/grid/tria_boundary_lib.cc +++ b/source/grid/tria_boundary_lib.cc @@ -601,10 +601,8 @@ HyperBallBoundary::get_intermediate_points_between_points ( else r = radius; - - const double r2=r*r; - Assert(std::fabs(v0*v0-r2) pm=0.5*(v0+v1); diff --git a/source/opencascade/boundary_lib.cc b/source/opencascade/boundary_lib.cc index aeebc80e8d..32b0f433da 100644 --- a/source/opencascade/boundary_lib.cc +++ b/source/opencascade/boundary_lib.cc @@ -119,11 +119,8 @@ namespace OpenCASCADE tolerance(tolerance) { Assert(spacedim == 3, ExcNotImplemented()); - - std_cxx11::tuple - counts = count_elements(sh); - - Assert(std_cxx11::get<0>(counts) > 0, ExcMessage("NormalToMeshProjectionBoundary needs a shape containing faces to operate.")); + Assert(std_cxx11::get<0>(count_elements(sh)) > 0, + ExcMessage("NormalToMeshProjectionBoundary needs a shape containing faces to operate.")); }