diff --git a/tests/test_circular_q.cpp b/tests/test_circular_q.cpp index 01f5b105..6a2ffa72 100644 --- a/tests/test_circular_q.cpp +++ b/tests/test_circular_q.cpp @@ -26,7 +26,8 @@ TEST_CASE("test_rolling", "[circular_q]") for (size_t i = 0; i < q_size + 2; i++) { - q.push_back(std::move(i)); // arg to push_back must be r value + auto val = i; + q.push_back(std::move(val)); // arg to push_back must be r value } REQUIRE(q.size() == q_size);