diff options
| author | bors <bors@rust-lang.org> | 2017-05-02 14:56:11 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2017-05-02 14:56:11 +0000 |
| commit | ed1f26ddda15b2bcf613a257e813e8b02ee14dff (patch) | |
| tree | 4bc9cd842d2113827d984404610e91f183dd62bd /src/librustdoc | |
| parent | 96e2c34286099eea4f51daaadbb82a8fbe99e0f6 (diff) | |
| parent | e0bfd19add662c07eb102818ce579315ddc90094 (diff) | |
| download | rust-ed1f26ddda15b2bcf613a257e813e8b02ee14dff.tar.gz rust-ed1f26ddda15b2bcf613a257e813e8b02ee14dff.zip | |
Auto merge of #41702 - frewsxcv:rollup, r=frewsxcv
Rollup of 6 pull requests - Successful merges: #41661, #41662, #41673, #41688, #41692, #41693 - Failed merges:
Diffstat (limited to 'src/librustdoc')
| -rw-r--r-- | src/librustdoc/clean/mod.rs | 12 | ||||
| -rw-r--r-- | src/librustdoc/core.rs | 2 | ||||
| -rw-r--r-- | src/librustdoc/html/highlight.rs | 8 |
3 files changed, 13 insertions, 9 deletions
diff --git a/src/librustdoc/clean/mod.rs b/src/librustdoc/clean/mod.rs index a25eb60d2a2..0a748487244 100644 --- a/src/librustdoc/clean/mod.rs +++ b/src/librustdoc/clean/mod.rs @@ -503,7 +503,7 @@ impl<'a> Iterator for ListAttributesIter<'a> { pub trait AttributesExt { /// Finds an attribute as List and returns the list of attributes nested inside. - fn lists<'a>(&'a self, &'a str) -> ListAttributesIter<'a>; + fn lists<'a>(&'a self, name: &'a str) -> ListAttributesIter<'a>; } impl AttributesExt for [ast::Attribute] { @@ -518,7 +518,7 @@ impl AttributesExt for [ast::Attribute] { pub trait NestedAttributesExt { /// Returns whether the attribute list contains a specific `Word` - fn has_word(self, &str) -> bool; + fn has_word(self, word: &str) -> bool; } impl<I: IntoIterator<Item=ast::NestedMetaItem>> NestedAttributesExt for I { @@ -726,7 +726,7 @@ impl<'tcx> Clean<TyParamBound> for ty::TraitRef<'tcx> { if let ty::TyTuple(ts, _) = ty_s.sty { for &ty_s in ts { if let ty::TyRef(ref reg, _) = ty_s.sty { - if let &ty::Region::ReLateBound(..) = *reg { + if let &ty::RegionKind::ReLateBound(..) = *reg { debug!(" hit an ReLateBound {:?}", reg); if let Some(lt) = reg.clean(cx) { late_bounds.push(lt); @@ -819,7 +819,7 @@ impl Clean<Lifetime> for ty::RegionParameterDef { } } -impl Clean<Option<Lifetime>> for ty::Region { +impl<'tcx> Clean<Option<Lifetime>> for ty::RegionKind<'tcx> { fn clean(&self, cx: &DocContext) -> Option<Lifetime> { match *self { ty::ReStatic => Some(Lifetime::statik()), @@ -915,7 +915,7 @@ impl<'tcx> Clean<WherePredicate> for ty::SubtypePredicate<'tcx> { } } -impl<'tcx> Clean<WherePredicate> for ty::OutlivesPredicate<&'tcx ty::Region, &'tcx ty::Region> { +impl<'tcx> Clean<WherePredicate> for ty::OutlivesPredicate<ty::Region<'tcx>, ty::Region<'tcx>> { fn clean(&self, cx: &DocContext) -> WherePredicate { let ty::OutlivesPredicate(ref a, ref b) = *self; WherePredicate::RegionPredicate { @@ -925,7 +925,7 @@ impl<'tcx> Clean<WherePredicate> for ty::OutlivesPredicate<&'tcx ty::Region, &'t } } -impl<'tcx> Clean<WherePredicate> for ty::OutlivesPredicate<ty::Ty<'tcx>, &'tcx ty::Region> { +impl<'tcx> Clean<WherePredicate> for ty::OutlivesPredicate<ty::Ty<'tcx>, ty::Region<'tcx>> { fn clean(&self, cx: &DocContext) -> WherePredicate { let ty::OutlivesPredicate(ref ty, ref lt) = *self; diff --git a/src/librustdoc/core.rs b/src/librustdoc/core.rs index 6417270b9c7..5879be08881 100644 --- a/src/librustdoc/core.rs +++ b/src/librustdoc/core.rs @@ -89,7 +89,7 @@ impl<'a, 'tcx> DocContext<'a, 'tcx> { } pub trait DocAccessLevels { - fn is_doc_reachable(&self, DefId) -> bool; + fn is_doc_reachable(&self, did: DefId) -> bool; } impl DocAccessLevels for AccessLevels<DefId> { diff --git a/src/librustdoc/html/highlight.rs b/src/librustdoc/html/highlight.rs index 15dada10c0d..a40d1e6bdc9 100644 --- a/src/librustdoc/html/highlight.rs +++ b/src/librustdoc/html/highlight.rs @@ -114,7 +114,7 @@ pub enum Class { pub trait Writer { /// Called when we start processing a span of text that should be highlighted. /// The `Class` argument specifies how it should be highlighted. - fn enter_span(&mut self, Class) -> io::Result<()>; + fn enter_span(&mut self, _: Class) -> io::Result<()>; /// Called at the end of a span of highlighted text. fn exit_span(&mut self) -> io::Result<()>; @@ -131,7 +131,11 @@ pub trait Writer { /// ``` /// The latter can be thought of as a shorthand for the former, which is /// more flexible. - fn string<T: Display>(&mut self, T, Class, Option<&TokenAndSpan>) -> io::Result<()>; + fn string<T: Display>(&mut self, + text: T, + klass: Class, + tok: Option<&TokenAndSpan>) + -> io::Result<()>; } // Implement `Writer` for anthing that can be written to, this just implements |
