about summary refs log tree commit diff
path: root/tests/rustdoc/intra-doc-link-method-trait-impl-72340.rs
blob: 880a308f9ab1162c19201b76b60a3546fef1915e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// https://github.com/rust-lang/rust/issues/72340

#![crate_name = "foo"]

pub struct Body;

impl Body {
    pub fn empty() -> Self {
        Body
    }

}

impl Default for Body {
    // @has foo/struct.Body.html '//a/@href' 'struct.Body.html#method.empty'

    /// Returns [`Body::empty()`](Body::empty).
    fn default() -> Body {
        Body::empty()
    }
}