From 30dbbecd456cfe00aa0d3fbcdf4bd3b3b5ed69db Mon Sep 17 00:00:00 2001 From: Matthias Maier Date: Wed, 15 Mar 2017 14:04:45 -0500 Subject: [PATCH] Fix unused variable warnings in step-23 --- examples/step-23/step-23.cc | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/examples/step-23/step-23.cc b/examples/step-23/step-23.cc index ee15a4587e..03089ec69c 100644 --- a/examples/step-23/step-23.cc +++ b/examples/step-23/step-23.cc @@ -185,7 +185,8 @@ namespace Step23 double InitialValuesU::value (const Point &/*p*/, const unsigned int component) const { - Assert (component == 0, ExcInternalError()); + (void) component; + Assert(component == 0, ExcIndexRange(component, 0, 1)); return 0; } @@ -195,7 +196,8 @@ namespace Step23 double InitialValuesV::value (const Point &/*p*/, const unsigned int component) const { - Assert (component == 0, ExcInternalError()); + (void) component; + Assert(component == 0, ExcIndexRange(component, 0, 1)); return 0; } @@ -219,7 +221,8 @@ namespace Step23 double RightHandSide::value (const Point &/*p*/, const unsigned int component) const { - Assert (component == 0, ExcInternalError()); + (void) component; + Assert(component == 0, ExcIndexRange(component, 0, 1)); return 0; } @@ -257,7 +260,8 @@ namespace Step23 double BoundaryValuesU::value (const Point &p, const unsigned int component) const { - Assert (component == 0, ExcInternalError()); + (void) component; + Assert(component == 0, ExcIndexRange(component, 0, 1)); if ((this->get_time() <= 0.5) && (p[0] < 0) && @@ -274,7 +278,8 @@ namespace Step23 double BoundaryValuesV::value (const Point &p, const unsigned int component) const { - Assert (component == 0, ExcInternalError()); + (void) component; + Assert(component == 0, ExcIndexRange(component, 0, 1)); if ((this->get_time() <= 0.5) && (p[0] < 0) && -- 2.39.5