• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# How to Contribute
2
3See the [clap-wide CONTRIBUTING.md](../CONTRIBUTING.md).  This will contain `clap_derive` specific notes.
4
5## Derive Gotchas
6
7- Always prefix generated variables with `__clap_` to minimize clashes with the user's variables, see [#2934](https://github.com/clap-rs/clap/issues/2934).
8- Prefer the path `clap` over `::clap` to allow users to re-export clap, see [#2258](https://github.com/clap-rs/clap/pull/2258).
9- Prefer substituting variable names to avoid problems with `macro_rules`, see [#2823](https://github.com/clap-rs/clap/pull/2823).
10- Prefer `::std::result::Result` and `::std::option::Option`, see [#3092](https://github.com/clap-rs/clap/pull/3092).
11- Put whitespace between `#quoted #variables`.
12