Revert "[clang-tidy] Simplify boolean expressions"

This reverts commit 51870dff34.
This commit is contained in:
Paul Beckingham
2020-12-05 16:18:15 -05:00
parent 623d5ceb59
commit 364b4ea8bd
8 changed files with 51 additions and 25 deletions

View File

@@ -73,7 +73,7 @@ void Filter::subset (const std::vector <Task>& input, std::vector <Task>& output
// Debug output from Eval during compilation is useful. During evaluation
// it is mostly noise.
eval.debug (Context::getContext ().config.getInteger ("debug.parser") >= 3);
eval.debug (Context::getContext ().config.getInteger ("debug.parser") >= 3 ? true : false);
eval.compileExpression (precompiled);
for (auto& task : input)
@@ -124,7 +124,7 @@ void Filter::subset (std::vector <Task>& output)
// Debug output from Eval during compilation is useful. During evaluation
// it is mostly noise.
eval.debug (Context::getContext ().config.getInteger ("debug.parser") >= 3);
eval.debug (Context::getContext ().config.getInteger ("debug.parser") >= 3 ? true : false);
eval.compileExpression (precompiled);
output.clear ();
@@ -240,10 +240,16 @@ bool Filter::pendingOnly () const
if (countStatus)
{
return !(!countPending && !countWaiting && !countRecurring);
if (!countPending && !countWaiting && !countRecurring)
return false;
return true;
}
return countId != 0;
if (countId)
return true;
return false;
}
////////////////////////////////////////////////////////////////////////////////