Files
rust/src/test/rustdoc/attributes.rs

14 lines
369 B
Rust
Raw Normal View History

#![crate_name = "foo"]
2021-04-12 23:03:17 -07:00
// @has foo/fn.f.html '//*[@class="rust fn"]' '#[no_mangle]'
#[no_mangle]
pub extern "C" fn f() {}
2021-04-12 23:03:17 -07:00
// @has foo/fn.g.html '//*[@class="rust fn"]' '#[export_name = "bar"]'
#[export_name = "bar"]
pub extern "C" fn g() {}
2021-04-12 23:03:17 -07:00
// @has foo/struct.Repr.html '//*[@class="docblock type-decl"]' '#[repr(C, align(8))]'
2020-03-03 23:41:32 +00:00
#[repr(C, align(8))]
pub struct Repr;