mirror of
https://github.com/clap-rs/clap
synced 2024-11-10 06:44:16 +00:00
docs(derive): Ensure magic attributes are searchable
This commit is contained in:
parent
c94ae5f7a7
commit
ffbe6e9936
2 changed files with 16 additions and 0 deletions
|
@ -9,3 +9,5 @@ See the [clap-wide CONTRIBUTING.md](../CONTRIBUTING.md). This will contain `cla
|
|||
- Prefer substituting variable names to avoid problems with `macro_rules`, see [#2823](https://github.com/clap-rs/clap/pull/2823).
|
||||
- Prefer `::std::result::Result` and `::std::option::Option`, see [#3092](https://github.com/clap-rs/clap/pull/3092).
|
||||
- Put whitespace between `#quoted #variables`.
|
||||
- New "magic" attributes must be documented in the [derive reference](../src/_derive.rs)
|
||||
- If there is no related builder method, a `#![doc(alias = "")]` should also be added, see [#4984](https://github.com/clap-rs/clap/pull/4984)
|
||||
|
|
|
@ -485,6 +485,20 @@
|
|||
//! ([example][_tutorial#testing])
|
||||
//! - Always remember to [document](#doc-comments) args and commands with `#![deny(missing_docs)]`
|
||||
|
||||
// Point people here that search for attributes that don't exist in the derive (a subset of magic
|
||||
// attributes)
|
||||
#![doc(alias = "skip")]
|
||||
#![doc(alias = "verbatim_doc_comment")]
|
||||
#![doc(alias = "flatten")]
|
||||
#![doc(alias = "external_subcommand")]
|
||||
#![doc(alias = "subcommand")]
|
||||
#![doc(alias = "rename_all")]
|
||||
#![doc(alias = "rename_all_env")]
|
||||
#![doc(alias = "default_value_t")]
|
||||
#![doc(alias = "default_values_t")]
|
||||
#![doc(alias = "default_value_os_t")]
|
||||
#![doc(alias = "default_values_os_t")]
|
||||
|
||||
pub mod _tutorial;
|
||||
#[doc(inline)]
|
||||
pub use crate::_cookbook;
|
||||
|
|
Loading…
Reference in a new issue