0
0
mirror of https://github.com/rust-lang/rust.git synced 2024-11-25 04:06:55 +01:00
rust/tests/rustdoc/all.rs
2024-06-24 11:08:41 +02:00

29 lines
794 B
Rust

#![crate_name = "foo"]
//@ has foo/all.html '//a[@href="struct.Struct.html"]' 'Struct'
//@ has foo/all.html '//a[@href="enum.Enum.html"]' 'Enum'
//@ has foo/all.html '//a[@href="union.Union.html"]' 'Union'
//@ has foo/all.html '//a[@href="constant.CONST.html"]' 'CONST'
//@ has foo/all.html '//a[@href="static.STATIC.html"]' 'STATIC'
//@ has foo/all.html '//a[@href="fn.function.html"]' 'function'
pub struct Struct;
pub enum Enum {
X,
Y,
}
pub union Union {
x: u32,
}
pub const CONST: u32 = 0;
pub static STATIC: &str = "baguette";
pub fn function() {}
mod private_module {
pub struct ReexportedStruct;
}
//@ has foo/all.html '//a[@href="struct.ReexportedStruct.html"]' 'ReexportedStruct'
//@ !hasraw foo/all.html 'private_module'
pub use private_module::ReexportedStruct;