From 87f3d6bb40bfb23b75b36d01779d60febd710e79 Mon Sep 17 00:00:00 2001 From: Chris Hennes Date: Tue, 13 May 2025 23:31:26 -0500 Subject: [PATCH] Gui: Eliminate signed-to-unsigned comparison `std::numeric_limits::max()` can losslessly be cast to an unsigned int to silence the compiler warning about comparison of signed to unsigned. --- src/Gui/SpinBox.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Gui/SpinBox.cpp b/src/Gui/SpinBox.cpp index 7ccfdccdd1..ca0bae7f60 100644 --- a/src/Gui/SpinBox.cpp +++ b/src/Gui/SpinBox.cpp @@ -319,7 +319,7 @@ public: in = int_limits::max(); } else if ( v == 0 ) { in = int_limits::min(); - } else if ( v > int_limits::max() ) { + } else if ( v > static_cast(int_limits::max()) ) { v += int_limits::min(); in = static_cast(v); } else {