From 780d7482dacc3e0ad1baaaf27861fb7f961cb1cf Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Mon, 3 Dec 2018 21:48:00 +0100 Subject: [PATCH] Fix muparse and change a unsigned type --- bundled/muparser_v2_2_4/src/muParserBase.cpp | 4 ++-- examples/step-44/step-44.cc | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/bundled/muparser_v2_2_4/src/muParserBase.cpp b/bundled/muparser_v2_2_4/src/muParserBase.cpp index 770606e7ac..09b0230bf0 100644 --- a/bundled/muparser_v2_2_4/src/muParserBase.cpp +++ b/bundled/muparser_v2_2_4/src/muParserBase.cpp @@ -1040,8 +1040,8 @@ namespace mu --sidx; Stack[sidx] = MathImpl::Pow(Stack[sidx], Stack[1+sidx]); continue; - case cmLAND: --sidx; Stack[sidx] = Stack[sidx] && Stack[sidx+1]; continue; - case cmLOR: --sidx; Stack[sidx] = Stack[sidx] || Stack[sidx+1]; continue; + case cmLAND: --sidx; Stack[sidx] = (Stack[sidx] != 0.) && (Stack[sidx+1] != 0.); continue; + case cmLOR: --sidx; Stack[sidx] = (Stack[sidx] != 0.) || (Stack[sidx+1] != 0.); continue; case cmASSIGN: // Bugfix for Bulkmode: diff --git a/examples/step-44/step-44.cc b/examples/step-44/step-44.cc index c40d4af574..249b66d05a 100644 --- a/examples/step-44/step-44.cc +++ b/examples/step-44/step-44.cc @@ -3052,9 +3052,9 @@ namespace Step44 std::cout << " SLV " << std::flush; if (parameters.type_lin == "CG") { - const int solver_its = - static_cast(tangent_matrix.block(u_dof, u_dof).m() * - parameters.max_iterations_lin); + const auto solver_its = static_cast( + tangent_matrix.block(u_dof, u_dof).m() * + parameters.max_iterations_lin); const double tol_sol = parameters.tol_lin * system_rhs.block(u_dof).l2_norm(); -- 2.39.5