From d76229eb025d702d22c61b7b9a7f9336c4385ad9 Mon Sep 17 00:00:00 2001 From: Zibi Sarbinowski Date: Thu, 28 Aug 2025 20:14:34 +0000 Subject: [PATCH] Fix random_shuffle in __cxx03/__algorithm/shuffle.h --- libcxx/include/__cxx03/__algorithm/shuffle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libcxx/include/__cxx03/__algorithm/shuffle.h b/libcxx/include/__cxx03/__algorithm/shuffle.h index fee7028ae22ac..24cd71c71378b 100644 --- a/libcxx/include/__cxx03/__algorithm/shuffle.h +++ b/libcxx/include/__cxx03/__algorithm/shuffle.h @@ -109,7 +109,7 @@ _LIBCPP_HIDE_FROM_ABI void random_shuffle(_RandomAccessIterator __first, _Random template _LIBCPP_HIDE_FROM_ABI void -random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last, _RandomNumberGenerator&& __rand) { +random_shuffle(_RandomAccessIterator __first, _RandomAccessIterator __last, _RandomNumberGenerator& __rand) { typedef typename iterator_traits<_RandomAccessIterator>::difference_type difference_type; difference_type __d = __last - __first; if (__d > 1) {