valentynkit · GitHub

Feature gate: #![feature(str_copy_from_str)]

This is a tracking issue for str::copy_from_str, which copies a same-length &str into a mutable str in place.

Public API

impl str {
    // Panics if `self.len() != src.len()`.
    pub fn copy_from_str(&mut self, src: &str);
}

Steps / History

Unresolved Questions

  • None known. The ACP accepted copy_from_str and rejected copy_within; swap_with_str was left out pending a concrete use case.

Footnotes

  1. https://std-dev-guide.rust-lang.org/feature-lifecycle/stabilization.html

Read the original on github.com ↗