]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_typeck/impl_wf_check.rs
Auto merge of #58341 - alexreg:cosmetic-2-doc-comments, r=steveklabnik
[rust.git] / src / librustc_typeck / impl_wf_check.rs
index 6de06b64816959334d2ff3199649087a532f765e..ed39874eeaadafa880f0b5fd0c6574e609651af8 100644 (file)
 use syntax_pos::Span;
 
 /// Checks that all the type/lifetime parameters on an impl also
-/// appear in the trait ref or self-type (or are constrained by a
+/// appear in the trait ref or self type (or are constrained by a
 /// where-clause). These rules are needed to ensure that, given a
 /// trait ref like `<T as Trait<U>>`, we can derive the values of all
 /// parameters on the impl (which is needed to make specialization
 /// possible).
 ///
 /// However, in the case of lifetimes, we only enforce these rules if
-/// the lifetime parameter is used in an associated type.  This is a
+/// the lifetime parameter is used in an associated type. This is a
 /// concession to backwards compatibility; see comment at the end of
 /// the fn for details.
 ///
@@ -40,7 +40,7 @@
 /// impl<T> Trait<Foo<T>> for Bar { ... }
 /// //   ^ T appears in `Foo<T>`, ok.
 ///
-/// impl<T> Trait<Foo> for Bar where Bar: Iterator<Item=T> { ... }
+/// impl<T> Trait<Foo> for Bar where Bar: Iterator<Item = T> { ... }
 /// //   ^ T is bound to `<Bar as Iterator>::Item`, ok.
 ///
 /// impl<'a> Trait<Foo> for Bar { }