Skip to content

Commit 46f24c9

Browse files
Add tests for !Sized trait display
1 parent d20e05b commit 46f24c9

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

src/test/rustdoc/sized_trait.rs

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#![crate_name = "foo"]
2+
3+
// @has foo/struct.Bar.html
4+
// @!has - '//h3[@id="impl-Sized"]'
5+
pub struct Bar {
6+
a: u16,
7+
}
8+
9+
// @has foo/struct.Foo.html
10+
// @!has - '//h3[@id="impl-Sized"]'
11+
pub struct Foo<T: ?Sized>(T);
12+
13+
// @has foo/struct.Unsized.html
14+
// @has - '//h3[@id="impl-Sized"]/code' 'impl !Sized for Unsized'
15+
pub struct Unsized {
16+
data: [u8],
17+
}

0 commit comments

Comments
 (0)