Skip to content

Commit 2ba8606

Browse files
committed
Rollup merge of rust-lang#32608 - tshepang:grammar, r=aturon
doc: "of the" seems more correct than "to the" It's also less ambiguous
2 parents 709be98 + 65cdf5d commit 2ba8606

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/libstd/env.rs

+8-8
Original file line numberDiff line numberDiff line change
@@ -416,7 +416,7 @@ impl Error for JoinPathsError {
416416
fn description(&self) -> &str { self.inner.description() }
417417
}
418418

419-
/// Returns the path to the current user's home directory if known.
419+
/// Returns the path of the current user's home directory if known.
420420
///
421421
/// # Unix
422422
///
@@ -450,7 +450,7 @@ pub fn home_dir() -> Option<PathBuf> {
450450
os_imp::home_dir()
451451
}
452452

453-
/// Returns the path to a temporary directory.
453+
/// Returns the path of a temporary directory.
454454
///
455455
/// On Unix, returns the value of the 'TMPDIR' environment variable if it is
456456
/// set, otherwise for non-Android it returns '/tmp'. If Android, since there
@@ -459,7 +459,7 @@ pub fn home_dir() -> Option<PathBuf> {
459459
///
460460
/// On Windows, returns the value of, in order, the 'TMP', 'TEMP',
461461
/// 'USERPROFILE' environment variable if any are set and not the empty
462-
/// string. Otherwise, tmpdir returns the path to the Windows directory. This
462+
/// string. Otherwise, tmpdir returns the path of the Windows directory. This
463463
/// behavior is identical to that of [GetTempPath][msdn], which this function
464464
/// uses internally.
465465
///
@@ -482,14 +482,14 @@ pub fn temp_dir() -> PathBuf {
482482
os_imp::temp_dir()
483483
}
484484

485-
/// Returns the full filesystem path to the current running executable.
485+
/// Returns the full filesystem path of the current running executable.
486486
///
487-
/// The path returned is not necessarily a "real path" to the executable as
487+
/// The path returned is not necessarily a "real path" of the executable as
488488
/// there may be intermediate symlinks.
489489
///
490490
/// # Errors
491491
///
492-
/// Acquiring the path to the current executable is a platform-specific operation
492+
/// Acquiring the path of the current executable is a platform-specific operation
493493
/// that can fail for a good number of reasons. Some errors can include, but not
494494
/// be limited to, filesystem operations failing or general syscall failures.
495495
///
@@ -526,7 +526,7 @@ pub struct ArgsOs { inner: os_imp::Args }
526526
/// Returns the arguments which this program was started with (normally passed
527527
/// via the command line).
528528
///
529-
/// The first element is traditionally the path to the executable, but it can be
529+
/// The first element is traditionally the path of the executable, but it can be
530530
/// set to arbitrary text, and may not even exist. This means this property should
531531
/// not be relied upon for security purposes.
532532
///
@@ -554,7 +554,7 @@ pub fn args() -> Args {
554554
/// Returns the arguments which this program was started with (normally passed
555555
/// via the command line).
556556
///
557-
/// The first element is traditionally the path to the executable, but it can be
557+
/// The first element is traditionally the path of the executable, but it can be
558558
/// set to arbitrary text, and it may not even exist, so this property should
559559
/// not be relied upon for security purposes.
560560
///

0 commit comments

Comments
 (0)