Skip to content

Commit

Permalink
Rollup merge of rust-lang#39697 - notriddle:rustdoc_tooltip, r=Guilla…
Browse files Browse the repository at this point in the history
  • Loading branch information
GuillaumeGomez authored Feb 12, 2017
2 parents 747b9e5 + bc4ad1a commit 0095ec2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/librustdoc/html/format.rs
Original file line number Diff line number Diff line change
Expand Up @@ -550,8 +550,8 @@ impl<'a> fmt::Display for HRef<'a> {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match href(self.did) {
Some((url, shortty, fqp)) => if !f.alternate() {
write!(f, "<a class='{}' href='{}' title='{}'>{}</a>",
shortty, url, fqp.join("::"), self.text)
write!(f, "<a class='{}' href='{}' title='{} {}'>{}</a>",
shortty, url, shortty, fqp.join("::"), self.text)
} else {
write!(f, "{}", self.text)
},
Expand Down
3 changes: 2 additions & 1 deletion src/librustdoc/html/render.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1818,7 +1818,7 @@ fn item_module(w: &mut fmt::Formatter, cx: &Context,
write!(w, "
<tr class='{stab} module-item'>
<td><a class='{class}' href='{href}'
title='{title}'>{name}</a>{unsafety_flag}</td>
title='{title_type} {title}'>{name}</a>{unsafety_flag}</td>
<td class='docblock-short'>
{stab_docs} {docs}
</td>
Expand All @@ -1830,6 +1830,7 @@ fn item_module(w: &mut fmt::Formatter, cx: &Context,
stab = myitem.stability_class(),
unsafety_flag = unsafety_flag,
href = item_path(myitem.type_(), myitem.name.as_ref().unwrap()),
title_type = myitem.type_(),
title = full_path(cx, myitem))?;
}
}
Expand Down

0 comments on commit 0095ec2

Please sign in to comment.