Skip to content

Commit c185f08

Browse files
committed
Add doc alias for chdir to std::env::set_current_dir
Searching for `chdir` in the Rust documentation produces no useful results.
1 parent 814a560 commit c185f08

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

library/std/src/env.rs

+1
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ pub fn current_dir() -> io::Result<PathBuf> {
6161
/// assert!(env::set_current_dir(&root).is_ok());
6262
/// println!("Successfully changed working directory to {}!", root.display());
6363
/// ```
64+
#[doc(alias = "chdir")]
6465
#[stable(feature = "env", since = "1.0.0")]
6566
pub fn set_current_dir<P: AsRef<Path>>(path: P) -> io::Result<()> {
6667
os_imp::chdir(path.as_ref())

0 commit comments

Comments
 (0)