We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
PathBuf
1 parent 316a15b commit 76824acCopy full SHA for 76824ac
std/src/path.rs
@@ -1158,6 +1158,7 @@ impl FusedIterator for Ancestors<'_> {}
1158
/// Note that `PathBuf` does not always sanitize arguments, for example
1159
/// [`push`] allows paths built from strings which include separators:
1160
///
1161
+/// ```
1162
/// use std::path::PathBuf;
1163
1164
/// let mut path = PathBuf::new();
@@ -1166,6 +1167,7 @@ impl FusedIterator for Ancestors<'_> {}
1166
1167
/// path.push("windows");
1168
/// path.push(r"..\otherdir");
1169
/// path.push("system32");
1170
1171
1172
/// The behavior of `PathBuf` may be changed to a panic on such inputs
1173
/// in the future. [`Extend::extend`] should be used to add multi-part paths.
0 commit comments