/// # Examples
///
/// ```
- /// # #![feature(core)]
- /// use std::str::Utf8Error;
- ///
/// let hello_vec = vec![104, 101, 108, 108, 111];
/// let s = String::from_utf8(hello_vec).unwrap();
/// assert_eq!(s, "hello");
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let s = String::from_str("hello");
+ /// let s = String::from("hello");
/// let bytes = s.into_bytes();
/// assert_eq!(bytes, [104, 101, 108, 108, 111]);
/// ```
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let mut s = String::from_str("foo");
+ /// let mut s = String::from("foo");
/// s.push_str("bar");
/// assert_eq!(s, "foobar");
/// ```
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let mut s = String::from_str("foo");
+ /// let mut s = String::from("foo");
/// s.reserve(100);
/// assert!(s.capacity() >= 100);
/// s.shrink_to_fit();
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let mut s = String::from_str("abc");
+ /// let mut s = String::from("abc");
/// s.push('1');
/// s.push('2');
/// s.push('3');
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let s = String::from_str("hello");
+ /// let s = String::from("hello");
/// let b: &[_] = &[104, 101, 108, 108, 111];
/// assert_eq!(s.as_bytes(), b);
/// ```
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let mut s = String::from_str("hello");
+ /// let mut s = String::from("hello");
/// s.truncate(2);
/// assert_eq!(s, "he");
/// ```
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let mut s = String::from_str("foo");
+ /// let mut s = String::from("foo");
/// assert_eq!(s.pop(), Some('o'));
/// assert_eq!(s.pop(), Some('o'));
/// assert_eq!(s.pop(), Some('f'));
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let mut s = String::from_str("foo");
+ /// let mut s = String::from("foo");
/// assert_eq!(s.remove(0), 'f');
/// assert_eq!(s.remove(1), 'o');
/// assert_eq!(s.remove(0), 'o');
/// # Examples
///
/// ```
- /// # #![feature(collections)]
- /// let mut s = String::from_str("hello");
+ /// let mut s = String::from("hello");
/// unsafe {
/// let vec = s.as_mut_vec();
/// assert!(vec == &[104, 101, 108, 108, 111]);