Rollup merge of #62821 - GuillaumeGomez:not-listed-methods, r=Mark-Simulacrum

Not listed methods

Fixes #60326.

cc @rust-lang/rustdoc
r? @QuietMisdreavus
This commit is contained in:
Mazdak Farrokhzad 2019-08-06 15:36:28 +02:00 committed by GitHub
commit e6994714d9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 34 additions and 3 deletions

View file

@ -0,0 +1,29 @@
#![crate_name = "foo"]
use std::ops;
pub struct Foo;
impl Foo {
pub fn foo(&mut self) {}
}
// @has foo/struct.Bar.html
// @has - '//div[@class="sidebar-links"]/a[@href="#method.foo"]' 'foo'
pub struct Bar {
foo: Foo,
}
impl ops::Deref for Bar {
type Target = Foo;
fn deref(&self) -> &Foo {
&self.foo
}
}
impl ops::DerefMut for Bar {
fn deref_mut(&mut self) -> &mut Foo {
&mut self.foo
}
}