rustc/vendor/doc-comment-0.3.3
2024-07-31 08:40:13 +02:00
..
src New upstream version 1.80.0+dfsg1 2024-07-31 08:40:13 +02:00
.cargo-checksum.json New upstream version 1.80.0+dfsg1 2024-07-31 08:40:13 +02:00
build.rs New upstream version 1.80.0+dfsg1 2024-07-31 08:40:13 +02:00
Cargo.toml New upstream version 1.80.0+dfsg1 2024-07-31 08:40:13 +02:00
LICENSE New upstream version 1.80.0+dfsg1 2024-07-31 08:40:13 +02:00
README.md New upstream version 1.80.0+dfsg1 2024-07-31 08:40:13 +02:00

doc-comment

Write doc comments from macros.

Usage example

// Of course, we need to import the `doc_comment` macro:
#[macro_use]
extern crate doc_comment;

// If you want to test examples in your README file.
doctest!("../README.md");

// If you want to test your README file ONLY on "cargo test":
#[cfg(doctest)]
doctest!("../README.md");

// If you want to document an item:
doc_comment!(concat!("fooo", "or not foo"), pub struct Foo {});

For more information, take a look at the documentation.