2018-07-21 13:19:17 +02:00
|
|
|
#![crate_name = "foo"]
|
|
|
|
|
|
|
|
|
|
use std::fmt;
|
|
|
|
|
|
2018-07-27 22:59:16 +02:00
|
|
|
// @!has foo/struct.Bar.html '//h3[@id="impl-ToString"]//code' 'impl<T> ToString for T'
|
2018-07-21 13:19:17 +02:00
|
|
|
pub struct Bar;
|
|
|
|
|
|
2018-07-27 22:59:16 +02:00
|
|
|
// @has foo/struct.Foo.html '//h3[@id="impl-ToString"]//code' 'impl<T> ToString for T'
|
2018-07-21 13:19:17 +02:00
|
|
|
pub struct Foo;
|
2018-07-29 16:47:31 +02:00
|
|
|
// @has foo/struct.Foo.html '//div[@class="sidebar-links"]/a[@href="#impl-ToString"]' 'ToString'
|
2018-07-21 13:19:17 +02:00
|
|
|
|
|
|
|
|
impl fmt::Display for Foo {
|
|
|
|
|
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
|
|
|
|
|
write!(f, "Foo")
|
|
|
|
|
}
|
|
|
|
|
}
|