rust/tests/rustdoc/intra-doc/anchors.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

25 lines
506 B
Rust
Raw Normal View History

2019-11-24 01:45:55 +08:00
/// I want...
///
/// # Anchor!
pub struct Something;
//@ has anchors/struct.SomeOtherType.html
//@ has - '//a/@href' 'struct.Something.html#Anchor!'
2019-11-24 01:45:55 +08:00
/// I want...
///
/// To link to [Something#Anchor!]
pub struct SomeOtherType;
/// Primitives?
///
/// [u32#hello]
//@ has anchors/fn.x.html
//@ has - '//a/@href' '{{channel}}/std/primitive.u32.html#hello'
pub fn x() {}
/// [prim@usize#x]
//@ has anchors/usize/index.html
//@ has - '//a/@href' '{{channel}}/std/primitive.usize.html#x'
pub mod usize {}