commit | 214e14c8151c70940889b2da33ff3256a49bff42 | [log] [tgz] |
---|---|---|
author | Bob Badour <[email protected]> | Thu Nov 10 21:24:27 2022 +0000 |
committer | Automerger Merge Worker <[email protected]> | Thu Nov 10 21:24:27 2022 +0000 |
tree | 174aa48b8917d398309920f3f7490feea580379b | |
parent | 59e10c820894c8829be83271c3bd1fffd7ac6fe6 [diff] | |
parent | 4272e46aaf4c8a552ac949f93f20f0460454f937 [diff] |
[LSC] Add LOCAL_LICENSE_KINDS to external/rust/crates/document-features am: 4272e46aaf Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/document-features/+/2297942 Change-Id: Ie5c9119f9d8e62975730c0c1bf6a03517a0b014e Signed-off-by: Automerger Merge Worker <[email protected]>
This crate provides a macro that extracts documentation comments from Cargo.toml
To use this crate, add #![doc = document_features::document_features!()]
in your crate documentation. The document_features!()
macro reads your Cargo.toml
file, extracts feature comments and generates a markdown string for your documentation.
Use ##
and #!
comments in your Cargo.toml to document features, for example:
[dependencies] document-features = "0.2" ## ... [features] ## The foo feature enables the `foo` functions foo = [] ## The bar feature enables the [`bar`] module bar = [] #! ### Experimental features #! The following features are experimental ## Activate the fusion reactor fusion = []
These comments keep the feature definition and documentation next to each other, and they are then rendered into your crate documentation.
Check out the documentation for more details.
Contributions are welcome. We accept pull requests and bug reports.
MIT OR Apache-2.0