]>
git.proxmox.com Git - rustc.git/blob - src/test/rustdoc/doc-notable_trait.rs
1 #![feature(doc_notable_trait)]
3 pub struct Wrapper
<T
> {
7 impl<T
: SomeTrait
> SomeTrait
for Wrapper
<T
> {}
11 // @has doc_notable_trait/trait.SomeTrait.html
12 // @has - '//a[@class="notable-traits"]/@data-ty' 'Wrapper<Self>'
13 // @snapshot wrap-me - '//script[@id="notable-traits-data"]'
14 fn wrap_me(self) -> Wrapper
<Self> where Self: Sized
{
21 pub struct SomeStruct
;
22 impl SomeTrait
for SomeStruct {}
25 // @has doc_notable_trait/struct.SomeStruct.html
26 // @has - '//a[@class="notable-traits"]/@data-ty' 'SomeStruct'
27 // @snapshot some-struct-new - '//script[@id="notable-traits-data"]'
28 pub fn new() -> SomeStruct
{
33 // @has doc_notable_trait/fn.bare_fn.html
34 // @has - '//a[@class="notable-traits"]/@data-ty' 'SomeStruct'
35 // @snapshot bare-fn - '//script[@id="notable-traits-data"]'
36 pub fn bare_fn() -> SomeStruct
{