about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2016-03-30 11:33:31 -0700
committerbors <bors@rust-lang.org>2016-03-30 11:33:31 -0700
commitbfacabc6a2b59771aa336ff420c363d9695a6ad2 (patch)
tree4b20bb126b45e2b7d4b7f941ac68b5acad25902b
parent102a5be7126ef8f1e79086b98d1d9faf47ba8ece (diff)
parent2ba860677c436e6aea62f2c64dca7a2c83384a31 (diff)
Auto merge of #32621 - steveklabnik:rollup, r=steveklabnik
Rollup of 7 pull requests

- Successful merges: #32580, #32591, #32603, #32605, #32606, #32607, #32608
- Failed merges:
-rw-r--r--COMPILER_TESTS.md2
-rw-r--r--src/doc/book/no-stdlib.md4
-rw-r--r--src/doc/book/vectors.md4
-rw-r--r--src/libcollections/binary_heap.rs2
-rw-r--r--src/libcore/convert.rs20
-rw-r--r--src/libstd/env.rs16
6 files changed, 24 insertions, 24 deletions
diff --git a/COMPILER_TESTS.md b/COMPILER_TESTS.md
index 1cae4ef090f..91975c1f9ed 100644
--- a/COMPILER_TESTS.md
+++ b/COMPILER_TESTS.md
@@ -77,7 +77,7 @@ fn test_foo() {
 }
 ```
 
-Note that not all headers have meaning when customized too a revision.
+Note that not all headers have meaning when customized to a revision.
 For example, the `ignore-test` header (and all "ignore" headers)
 currently only apply to the test as a whole, not to particular
 revisions. The only headers that are intended to really work when
diff --git a/src/doc/book/no-stdlib.md b/src/doc/book/no-stdlib.md
index 610940cde95..43bd0507ebb 100644
--- a/src/doc/book/no-stdlib.md
+++ b/src/doc/book/no-stdlib.md
@@ -38,7 +38,7 @@ fn start(_argc: isize, _argv: *const *const u8) -> isize {
 // for a bare-bones hello world. These are normally
 // provided by libstd.
 #[lang = "eh_personality"] extern fn eh_personality() {}
-#[lang = "panic_fmt"] fn panic_fmt() -> ! { loop {} }
+#[lang = "panic_fmt"] extern fn panic_fmt() -> ! { loop {} }
 # #[lang = "eh_unwind_resume"] extern fn rust_eh_unwind_resume() {}
 # #[no_mangle] pub extern fn rust_eh_register_frames () {}
 # #[no_mangle] pub extern fn rust_eh_unregister_frames () {}
@@ -65,7 +65,7 @@ pub extern fn main(argc: i32, argv: *const *const u8) -> i32 {
 }
 
 #[lang = "eh_personality"] extern fn eh_personality() {}
-#[lang = "panic_fmt"] fn panic_fmt() -> ! { loop {} }
+#[lang = "panic_fmt"] extern fn panic_fmt() -> ! { loop {} }
 # #[lang = "eh_unwind_resume"] extern fn rust_eh_unwind_resume() {}
 # #[no_mangle] pub extern fn rust_eh_register_frames () {}
 # #[no_mangle] pub extern fn rust_eh_unregister_frames () {}
diff --git a/src/doc/book/vectors.md b/src/doc/book/vectors.md
index 6ac701e2969..e96dddf8c82 100644
--- a/src/doc/book/vectors.md
+++ b/src/doc/book/vectors.md
@@ -120,7 +120,7 @@ You can iterate the vector multiple times by taking a reference to the vector wh
 For example, the following code does not compile.
 
 ```rust,ignore
-let mut v = vec![1, 2, 3, 4, 5];
+let v = vec![1, 2, 3, 4, 5];
 
 for i in v {
     println!("Take ownership of the vector and its element {}", i);
@@ -134,7 +134,7 @@ for i in v {
 Whereas the following works perfectly,
 
 ```rust
-let mut v = vec![1, 2, 3, 4, 5];
+let v = vec![1, 2, 3, 4, 5];
 
 for i in &v {
     println!("This is a reference to {}", i);
diff --git a/src/libcollections/binary_heap.rs b/src/libcollections/binary_heap.rs
index 188fd3f9d63..c9dd1efb374 100644
--- a/src/libcollections/binary_heap.rs
+++ b/src/libcollections/binary_heap.rs
@@ -194,7 +194,7 @@ use vec::{self, Vec};
 ///
 /// // We can iterate over the items in the heap, although they are returned in
 /// // a random order.
-/// for x in heap.iter() {
+/// for x in &heap {
 ///     println!("{}", x);
 /// }
 ///
diff --git a/src/libcore/convert.rs b/src/libcore/convert.rs
index b4ac020795c..2d999868f71 100644
--- a/src/libcore/convert.rs
+++ b/src/libcore/convert.rs
@@ -19,14 +19,14 @@
 //!
 //! - Impl the `As*` traits for reference-to-reference conversions
 //! - Impl the `Into` trait when you want to consume the value in the conversion
-//! - The `From` trait is the most flexible, useful for values _and_ references conversions
+//! - The `From` trait is the most flexible, useful for value _and_ reference conversions
 //!
-//! As a library writer, you should prefer implementing `From<T>` rather than
-//! `Into<U>`, as `From` provides greater flexibility and offer the equivalent `Into`
+//! As a library author, you should prefer implementing `From<T>` rather than
+//! `Into<U>`, as `From` provides greater flexibility and offers an equivalent `Into`
 //! implementation for free, thanks to a blanket implementation in the standard library.
 //!
 //! **Note: these traits must not fail**. If the conversion can fail, you must use a dedicated
-//! method which return an `Option<T>` or a `Result<T, E>`.
+//! method which returns an `Option<T>` or a `Result<T, E>`.
 //!
 //! # Generic impl
 //!
@@ -49,7 +49,7 @@ use marker::Sized;
 /// [book]: ../../book/borrow-and-asref.html
 ///
 /// **Note: this trait must not fail**. If the conversion can fail, use a dedicated method which
-/// return an `Option<T>` or a `Result<T, E>`.
+/// returns an `Option<T>` or a `Result<T, E>`.
 ///
 /// # Examples
 ///
@@ -82,7 +82,7 @@ pub trait AsRef<T: ?Sized> {
 /// A cheap, mutable reference-to-mutable reference conversion.
 ///
 /// **Note: this trait must not fail**. If the conversion can fail, use a dedicated method which
-/// return an `Option<T>` or a `Result<T, E>`.
+/// returns an `Option<T>` or a `Result<T, E>`.
 ///
 /// # Generic Impls
 ///
@@ -99,10 +99,10 @@ pub trait AsMut<T: ?Sized> {
 /// A conversion that consumes `self`, which may or may not be expensive.
 ///
 /// **Note: this trait must not fail**. If the conversion can fail, use a dedicated method which
-/// return an `Option<T>` or a `Result<T, E>`.
+/// returns an `Option<T>` or a `Result<T, E>`.
 ///
-/// Library writer should not implement directly this trait, but should prefer the implementation
-/// of the `From` trait, which offer greater flexibility and provide the equivalent `Into`
+/// Library authors should not directly implement this trait, but should prefer implementing
+/// the `From` trait, which offers greater flexibility and provides an equivalent `Into`
 /// implementation for free, thanks to a blanket implementation in the standard library.
 ///
 /// # Examples
@@ -134,7 +134,7 @@ pub trait Into<T>: Sized {
 /// Construct `Self` via a conversion.
 ///
 /// **Note: this trait must not fail**. If the conversion can fail, use a dedicated method which
-/// return an `Option<T>` or a `Result<T, E>`.
+/// returns an `Option<T>` or a `Result<T, E>`.
 ///
 /// # Examples
 ///
diff --git a/src/libstd/env.rs b/src/libstd/env.rs
index 749e58c1196..40f6528f63e 100644
--- a/src/libstd/env.rs
+++ b/src/libstd/env.rs
@@ -416,7 +416,7 @@ impl Error for JoinPathsError {
     fn description(&self) -> &str { self.inner.description() }
 }
 
-/// Returns the path to the current user's home directory if known.
+/// Returns the path of the current user's home directory if known.
 ///
 /// # Unix
 ///
@@ -450,7 +450,7 @@ pub fn home_dir() -> Option<PathBuf> {
     os_imp::home_dir()
 }
 
-/// Returns the path to a temporary directory.
+/// Returns the path of a temporary directory.
 ///
 /// On Unix, returns the value of the 'TMPDIR' environment variable if it is
 /// set, otherwise for non-Android it returns '/tmp'. If Android, since there
@@ -459,7 +459,7 @@ pub fn home_dir() -> Option<PathBuf> {
 ///
 /// On Windows, returns the value of, in order, the 'TMP', 'TEMP',
 /// 'USERPROFILE' environment variable  if any are set and not the empty
-/// string. Otherwise, tmpdir returns the path to the Windows directory. This
+/// string. Otherwise, tmpdir returns the path of the Windows directory. This
 /// behavior is identical to that of [GetTempPath][msdn], which this function
 /// uses internally.
 ///
@@ -482,14 +482,14 @@ pub fn temp_dir() -> PathBuf {
     os_imp::temp_dir()
 }
 
-/// Returns the full filesystem path to the current running executable.
+/// Returns the full filesystem path of the current running executable.
 ///
-/// The path returned is not necessarily a "real path" to the executable as
+/// The path returned is not necessarily a "real path" of the executable as
 /// there may be intermediate symlinks.
 ///
 /// # Errors
 ///
-/// Acquiring the path to the current executable is a platform-specific operation
+/// Acquiring the path of the current executable is a platform-specific operation
 /// that can fail for a good number of reasons. Some errors can include, but not
 /// be limited to, filesystem operations failing or general syscall failures.
 ///
@@ -526,7 +526,7 @@ pub struct ArgsOs { inner: os_imp::Args }
 /// Returns the arguments which this program was started with (normally passed
 /// via the command line).
 ///
-/// The first element is traditionally the path to the executable, but it can be
+/// The first element is traditionally the path of the executable, but it can be
 /// set to arbitrary text, and may not even exist. This means this property should
 /// not be relied upon for security purposes.
 ///
@@ -554,7 +554,7 @@ pub fn args() -> Args {
 /// Returns the arguments which this program was started with (normally passed
 /// via the command line).
 ///
-/// The first element is traditionally the path to the executable, but it can be
+/// The first element is traditionally the path of the executable, but it can be
 /// set to arbitrary text, and it may not even exist, so this property should
 /// not be relied upon for security purposes.
 ///