about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--compiler/rustc_ast/src/ast.rs2
-rw-r--r--library/core/src/ops/generator.rs2
-rw-r--r--library/core/src/pin.rs4
-rw-r--r--src/tools/lld-wrapper/src/main.rs2
4 files changed, 5 insertions, 5 deletions
diff --git a/compiler/rustc_ast/src/ast.rs b/compiler/rustc_ast/src/ast.rs
index e9135b71630..e616a09024c 100644
--- a/compiler/rustc_ast/src/ast.rs
+++ b/compiler/rustc_ast/src/ast.rs
@@ -285,7 +285,7 @@ impl ParenthesizedArgs {
 
 pub use crate::node_id::{NodeId, CRATE_NODE_ID, DUMMY_NODE_ID};
 
-/// A modifier on a bound, e.g., `?Sized` or `~const Trait`.
+/// A modifier on a bound, e.g., `?Trait` or `~const Trait`.
 ///
 /// Negative bounds should also be handled here.
 #[derive(Copy, Clone, PartialEq, Eq, Encodable, Decodable, Debug)]
diff --git a/library/core/src/ops/generator.rs b/library/core/src/ops/generator.rs
index 52a2e464e3a..7c3b2a644e8 100644
--- a/library/core/src/ops/generator.rs
+++ b/library/core/src/ops/generator.rs
@@ -47,7 +47,7 @@ pub enum GeneratorState<Y, R> {
 /// fn main() {
 ///     let mut generator = || {
 ///         yield 1;
-///         return "foo"
+///         "foo"
 ///     };
 ///
 ///     match Pin::new(&mut generator).resume(()) {
diff --git a/library/core/src/pin.rs b/library/core/src/pin.rs
index dec1b5270d5..d642df4f6a0 100644
--- a/library/core/src/pin.rs
+++ b/library/core/src/pin.rs
@@ -1100,8 +1100,8 @@ pub macro pin($value:expr $(,)?) {
     //     that would break `Pin`'s invariants.
     //   - `{ $value }` is braced, making it a _block expression_, thus **moving**
     //     the given `$value`, and making it _become an **anonymous** temporary_.
-    //     By virtue of being anonynomous, it can no longer be accessed, thus
-    //     preventing any attemps to `mem::replace` it or `mem::forget` it, _etc._
+    //     By virtue of being anonymous, it can no longer be accessed, thus
+    //     preventing any attempts to `mem::replace` it or `mem::forget` it, _etc._
     //
     // This gives us a `pin!` definition that is sound, and which works, but only
     // in certain scenarios:
diff --git a/src/tools/lld-wrapper/src/main.rs b/src/tools/lld-wrapper/src/main.rs
index 1601bf1b34e..8d19a054a1d 100644
--- a/src/tools/lld-wrapper/src/main.rs
+++ b/src/tools/lld-wrapper/src/main.rs
@@ -8,7 +8,7 @@
 //! In Rust with `-Z gcc-ld=lld` we have gcc or clang invoke rust-lld. Since there is no way to
 //! make gcc/clang pass `-flavor <flavor>` as the first two arguments in the linker invocation
 //! and since Windows does not support symbolic links for files this wrapper is used in place of a
-//! symblic link. It execs `../rust-lld -flavor ld` if the feature `ld` is enabled and
+//! symbolic link. It execs `../rust-lld -flavor ld` if the feature `ld` is enabled and
 //! `../rust-lld -flavor ld64` if `ld64` is enabled. On Windows it spawns a `..\rust-lld.exe`
 //! child process.