rust/tests/rustdoc/mixing-doc-comments-and-attrs.rs

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

26 lines
572 B
Rust
Raw Normal View History

#![crate_name = "foo"]
// @has 'foo/struct.S1.html'
// @snapshot S1_top-doc - '//details[@class="toggle top-doc"]/div[@class="docblock"]'
#[doc = "Hello world!\n\n"]
/// Goodbye!
#[doc = " Hello again!\n"]
pub struct S1;
// @has 'foo/struct.S2.html'
// @snapshot S2_top-doc - '//details[@class="toggle top-doc"]/div[@class="docblock"]'
/// Hello world!
///
#[doc = "Goodbye!"]
/// Hello again!
pub struct S2;
2022-01-01 04:04:44 -06:00
// @has 'foo/struct.S3.html'
// @snapshot S3_top-doc - '//details[@class="toggle top-doc"]/div[@class="docblock"]'
2022-01-01 04:04:44 -06:00
/** Par 1
*/ ///
/// Par 2
pub struct S3;