libstdc++: Add missing std::move to join_view::iterator ctor [PR101483]

Message ID 20210723163419.3292859-1-ppalka@redhat.com
State New
Headers show
Series
  • libstdc++: Add missing std::move to join_view::iterator ctor [PR101483]
Related show

Commit Message

Martin Sebor via Gcc-patches July 23, 2021, 4:34 p.m.
Tested on x86_64-pc-linux-gnu, does this look OK for trunk/branches?

	PR libstdc++/101483

libstdc++-v3/ChangeLog:

	* include/std/ranges (join_view::_Iterator::_Iterator): Add
	missing std::move.
---
 libstdc++-v3/include/std/ranges | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

-- 
2.32.0.349.gdaab8a564f

Comments

Martin Sebor via Gcc-patches July 23, 2021, 4:36 p.m. | #1
On Fri, 23 Jul 2021 at 17:36, Patrick Palka via Libstdc++
<libstdc++@gcc.gnu.org> wrote:
>

> Tested on x86_64-pc-linux-gnu, does this look OK for trunk/branches?


Yes, thanks.


>

>         PR libstdc++/101483

>

> libstdc++-v3/ChangeLog:

>

>         * include/std/ranges (join_view::_Iterator::_Iterator): Add

>         missing std::move.

> ---

>  libstdc++-v3/include/std/ranges | 2 +-

>  1 file changed, 1 insertion(+), 1 deletion(-)

>

> diff --git a/libstdc++-v3/include/std/ranges b/libstdc++-v3/include/std/ranges

> index 50b414e8c8c..5bdcd445a9e 100644

> --- a/libstdc++-v3/include/std/ranges

> +++ b/libstdc++-v3/include/std/ranges

> @@ -2588,7 +2588,7 @@ namespace views::__adaptor

>             requires _Const

>               && convertible_to<iterator_t<_Vp>, _Outer_iter>

>               && convertible_to<iterator_t<_InnerRange>, _Inner_iter>

> -           : _M_outer(std::move(__i._M_outer)), _M_inner(__i._M_inner),

> +           : _M_outer(std::move(__i._M_outer)), _M_inner(std::move(__i._M_inner)),

>               _M_parent(__i._M_parent)

>           { }

>

> --

> 2.32.0.349.gdaab8a564f

>

Patch

diff --git a/libstdc++-v3/include/std/ranges b/libstdc++-v3/include/std/ranges
index 50b414e8c8c..5bdcd445a9e 100644
--- a/libstdc++-v3/include/std/ranges
+++ b/libstdc++-v3/include/std/ranges
@@ -2588,7 +2588,7 @@  namespace views::__adaptor
 	    requires _Const
 	      && convertible_to<iterator_t<_Vp>, _Outer_iter>
 	      && convertible_to<iterator_t<_InnerRange>, _Inner_iter>
-	    : _M_outer(std::move(__i._M_outer)), _M_inner(__i._M_inner),
+	    : _M_outer(std::move(__i._M_outer)), _M_inner(std::move(__i._M_inner)),
 	      _M_parent(__i._M_parent)
 	  { }