https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63500
Marc Glisse <glisse at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Last reconfirmed| |2014-10-09 Summary|bug in debug version of |[4.9/5 Regression] bug in |std::make_move_iterator? |debug version of | |std::make_move_iterator? Ever confirmed|0 |1 --- Comment #2 from Marc Glisse <glisse at gcc dot gnu.org> --- Ah, no, not my fault. The debug machinery wants at some point __addressof(*iter) but addressof wants an lvalue reference so it is not happy with a move iterator. Note that the error message is confusing: error: invalid initialization of non-const reference of type 'std::unique_ptr<Foo>&' from an rvalue of type 'std::unique_ptr<Foo>' when it is really an xvalue of type unique_ptr<Foo>&&.