https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125693

--- Comment #7 from Marc Mutz <marc.mutz at hotmail dot com> ---
> v.emplace(v.begin(), std::string_view(v[1]));

That shouldn't actually copy, since it's an rvalue you're passing, and rvalues
ought not alias members of the containers (and the test confirms it works for
rvalues). But this should: v.emplace(v.begin(), v[1]);

Reply via email to