We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 12f029b commit fd4a88fCopy full SHA for fd4a88f
src/test/rustdoc/deref-typedef.rs
@@ -0,0 +1,19 @@
1
+#![crate_name = "foo"]
2
+
3
+// @has 'foo/struct.Bar.html'
4
+// @has '-' '//*[@id="deref-methods"]' 'Methods from Deref<Target = FooB>'
5
+// @has '-' '//*[@class="impl-items"]//*[@id="method.happy"]' 'pub fn happy(&self)'
6
+// @has '-' '//*[@class="sidebar-title"]' 'Methods from Deref<Target=FooB>'
7
+// @has '-' '//*[@class="sidebar-links"]/a[@href="#method.happy"]' 'happy'
8
+pub struct FooA;
9
+pub type FooB = FooA;
10
11
+impl FooA {
12
+ pub fn happy(&self) {}
13
+}
14
15
+pub struct Bar;
16
+impl std::ops::Deref for Bar {
17
+ type Target = FooB;
18
+ fn deref(&self) -> &FooB { unimplemented!() }
19
0 commit comments