@@ -429,8 +429,8 @@ pub enum BorrowKind {
429
429
430
430
/// Data must be immutable but not aliasable. This kind of borrow
431
431
/// cannot currently be expressed by the user and is used only in
432
- /// implicit closure bindings. It is needed when you the closure
433
- /// is borrowing or mutating a mutable referent, e.g.:
432
+ /// implicit closure bindings. It is needed when the closure is
433
+ /// borrowing or mutating a mutable referent, e.g.:
434
434
///
435
435
/// let x: &mut isize = ...;
436
436
/// let y = || *x += 5;
@@ -443,7 +443,7 @@ pub enum BorrowKind {
443
443
/// let y = (&mut Env { &x }, fn_ptr); // Closure is pair of env and fn
444
444
/// fn fn_ptr(env: &mut Env) { **env.x += 5; }
445
445
///
446
- /// This is then illegal because you cannot mutate a `&mut` found
446
+ /// This is then illegal because you cannot mutate an `&mut` found
447
447
/// in an aliasable location. To solve, you'd have to translate with
448
448
/// an `&mut` borrow:
449
449
///
@@ -673,7 +673,7 @@ pub struct LocalDecl<'tcx> {
673
673
/// ROOT SCOPE
674
674
/// │{ argument x: &str }
675
675
/// │
676
- /// │ │{ #[allow(unused_mut] } // this is actually split into 2 scopes
676
+ /// │ │{ #[allow(unused_mut) ] } // this is actually split into 2 scopes
677
677
/// │ │ // in practice because I'm lazy.
678
678
/// │ │
679
679
/// │ │← x.source_info.scope
@@ -906,7 +906,7 @@ pub enum TerminatorKind<'tcx> {
906
906
907
907
/// Drop the Place and assign the new value over it. This ensures
908
908
/// that the assignment to `P` occurs *even if* the destructor for
909
- /// place unwinds. Its semantics are best explained by by the
909
+ /// place unwinds. Its semantics are best explained by the
910
910
/// elaboration:
911
911
///
912
912
/// ```
0 commit comments