From 68ed5e0aca5a807de9e7e6b0ce48d52f2f8b0dc7 Mon Sep 17 00:00:00 2001 From: Kyle Isom Date: Fri, 20 Oct 2023 16:13:49 -0700 Subject: [PATCH] Minor code cleanups. --- include/scmp/filter/Madgwick.h | 5 +---- src/scmp/Math.cc | 2 +- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/include/scmp/filter/Madgwick.h b/include/scmp/filter/Madgwick.h index b10208b..3824662 100644 --- a/include/scmp/filter/Madgwick.h +++ b/include/scmp/filter/Madgwick.h @@ -136,10 +136,7 @@ public: UpdateAngularOrientation(const scmp::geom::Vector &gyro, T delta) { // Ensure the delta isn't zero within a 100 μs - // tolerance. The assert helps to catch bugs in - // testing, but otherwise we should refused to do - // anything. - assert(!scmp::WithinTolerance(delta, 0.0, 0.0001)); + // tolerance. if (scmp::WithinTolerance(delta, 0.0, 0.00001)) { return; } diff --git a/src/scmp/Math.cc b/src/scmp/Math.cc index 3f325fb..b24380c 100644 --- a/src/scmp/Math.cc +++ b/src/scmp/Math.cc @@ -55,7 +55,7 @@ BestDie(int k, int m, int n) auto dice = Die(m, n); if (k < m) { - std::sort(dice.begin(), dice.end(), std::greater()); + std::sort(dice.begin(), dice.end(), std::greater<>()); dice.resize(static_cast(k)); }