We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5263d62 commit 462829cCopy full SHA for 462829c
src/libstd/path.rs
@@ -1623,11 +1623,11 @@ impl Path {
1623
/// # Examples
1624
///
1625
/// ```
1626
- /// use std::path::Path;
+ /// use std::path::{self, Path};
1627
/// use std::ffi::OsStr;
1628
1629
/// let mut it = Path::new("/tmp/foo.txt").iter();
1630
- /// assert_eq!(it.next(), Some(OsStr::new("/")));
+ /// assert_eq!(it.next(), Some(OsStr::new(&path::MAIN_SEPARATOR.to_string())));
1631
/// assert_eq!(it.next(), Some(OsStr::new("tmp")));
1632
/// assert_eq!(it.next(), Some(OsStr::new("foo.txt")));
1633
/// assert_eq!(it.next(), None)
0 commit comments