From b641dbf5e1917e524e0e408d2c6730816861880b Mon Sep 17 00:00:00 2001 From: Nerixyz Date: Mon, 12 Aug 2024 12:26:19 +0200 Subject: [PATCH] Fix compilation with `-Wtype-limits` --- tests/coroutines/source/array_proxy_lifetime.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/coroutines/source/array_proxy_lifetime.cpp b/tests/coroutines/source/array_proxy_lifetime.cpp index 2e039f5d..320481ea 100644 --- a/tests/coroutines/source/array_proxy_lifetime.cpp +++ b/tests/coroutines/source/array_proxy_lifetime.cpp @@ -59,7 +59,7 @@ inline namespace sol2_regression_test_coroutines_array_proxy_lifetime { value_type operator*() const { size_t size = a.mpParent.children.size(); - if (index >= 0 && index < size) { + if (index < size) { return a.mpParent.children[index]; } return std::weak_ptr();