From 10c0110110870da658b2c6b0e459a7a0dbee89cc Mon Sep 17 00:00:00 2001 From: Pavel P Date: Wed, 9 Apr 2025 13:30:18 +0200 Subject: [PATCH] Remove unnecessary std::tie fixes #127 --- src/include/nanobench.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/include/nanobench.h b/src/include/nanobench.h index d233dcc..3ca9d51 100644 --- a/src/include/nanobench.h +++ b/src/include/nanobench.h @@ -1311,7 +1311,6 @@ void doNotOptimizeAway(T const& val) { # include // random_device # include // to_s in Number # include // throw for rendering templates -# include // std::tie # if defined(__linux__) # include //sysconf # endif @@ -3458,7 +3457,8 @@ double BigO::normalizedRootMeanSquare() const noexcept { } bool BigO::operator<(BigO const& other) const noexcept { - return std::tie(mNormalizedRootMeanSquare, mName) < std::tie(other.mNormalizedRootMeanSquare, other.mName); + return (mNormalizedRootMeanSquare < other.mNormalizedRootMeanSquare) + || (!(mNormalizedRootMeanSquare > other.mNormalizedRootMeanSquare) && mName < other.mName); } std::ostream& operator<<(std::ostream& os, BigO const& bigO) {