From 8fcc832198e86c4f3ff2912c5cfc91dc0896098b Mon Sep 17 00:00:00 2001 From: Andrew Wagner Date: Mon, 15 Dec 2014 10:22:49 +0100 Subject: Standardize some usages of "which" in docstrings In US english, "that" is used in restrictive clauses in place of "which", and often affects the meaning of sentences. In UK english and many dialects, no distinction is made. While Rust devs want to avoid unproductive pedanticism, it is worth at least being uniform in documentation such as: http://doc.rust-lang.org/std/iter/index.html and also in cases where correct usage of US english clarifies the sentence. --- src/libstd/io/fs.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/libstd/io') diff --git a/src/libstd/io/fs.rs b/src/libstd/io/fs.rs index da0834dc9ef..32f62427216 100644 --- a/src/libstd/io/fs.rs +++ b/src/libstd/io/fs.rs @@ -200,7 +200,7 @@ impl File { .update_desc("couldn't create file") } - /// Returns the original path which was used to open this file. + /// Returns the original path that was used to open this file. pub fn path<'a>(&'a self) -> &'a Path { &self.path } @@ -215,7 +215,7 @@ impl File { } /// This function is similar to `fsync`, except that it may not synchronize - /// file metadata to the filesystem. This is intended for use case which + /// file metadata to the filesystem. This is intended for use cases that /// must synchronize content, but don't need the metadata on disk. The goal /// of this method is to reduce disk operations. pub fn datasync(&mut self) -> IoResult<()> { @@ -456,7 +456,7 @@ pub fn symlink(src: &Path, dst: &Path) -> IoResult<()> { /// # Error /// /// This function will return an error on failure. Failure conditions include -/// reading a file that does not exist or reading a file which is not a symlink. +/// reading a file that does not exist or reading a file that is not a symlink. pub fn readlink(path: &Path) -> IoResult { fs_imp::readlink(path) .update_err("couldn't resolve symlink for path", |e| @@ -546,7 +546,7 @@ pub fn readdir(path: &Path) -> IoResult> { |e| format!("{}; path={}", e, path.display())) } -/// Returns an iterator which will recursively walk the directory structure +/// Returns an iterator that will recursively walk the directory structure /// rooted at `path`. The path given will not be iterated over, and this will /// perform iteration in some top-down order. The contents of unreadable /// subdirectories are ignored. @@ -557,7 +557,7 @@ pub fn walk_dir(path: &Path) -> IoResult { }) } -/// An iterator which walks over a directory +/// An iterator that walks over a directory pub struct Directories { stack: Vec, } -- cgit 1.4.1-3-g733a5