A full featured, fast Command Line Argument Parser for Rust
This report summarizes scanner evidence for clap-rs/clap, a Rust project with 16,765 GitHub stars. SynthScan examined 99,522 lines of code across 477 source files, recording 796 pattern matches distributed across 6 syntactic categories. The legacy adjusted pattern signal is 6.2 (Moderate pattern signal); it is not an authorship estimate.
Use the findings to ask whether maintainers can explain intent, verify dependencies, simplify unnecessary scaffolding, and focus review effort. Risk Payload v1 adds ownership, supply-chain, over-engineering, and review-effort vectors when available. These are prompts for human verification, not probabilities, security findings, or measured maintenance costs.
Use each vector to guide manual verification of the underlying findings.
Can maintainers explain intent, assumptions, and trade-offs? 777 finding(s).
Are imports declared and package/API names verified? 15 finding(s).
Are wrappers, guards, and repeated structures necessary? 4 finding(s).
Which changes need focused human review? 796 finding(s).
This chart tracks the legacy adjusted pattern score across scan runs. Changes can reflect source changes, scan coverage, or detector/scoring versions; they do not measure AI adoption or prove that a team refactored code. Compare runs only when their scoring versions are compatible. The dashed line tracks the raw pattern-hit count.
Groups findings by configured severity weight. Severity is not a confidence estimate, security rating, or proof that a package is missing. Verify imports against the project's manifests and inspect each finding in its local design context.
This horizontal bar chart shows where configured pattern scores accumulate across directories. Treat the bars as locations to inspect, not as evidence of authorship or code quality. Use the file-level findings to decide whether a directory needs a focused ownership, dependency, complexity, or review check.
The scanner identified 796 distinct pattern matches across 6 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a detector match to inspect in context. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.
Reading the findings table: The Severity column indicates the configured finding weight (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — legacy comment-context matches receive a ×1.5 score weight. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier under the legacy scoring model.
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | deny.toml | 1 | # Note that all fields that take a lint level have these possible values: | COMMENT |
| LOW | deny.toml | 21 | # The triple can be any string, but only the target triples built in to | COMMENT |
| LOW | deny.toml | 41 | # If true, metadata will be collected with `--no-default-features`. The same | COMMENT |
| LOW | deny.toml | 61 | # The path where the advisory databases are cloned/fetched into | COMMENT |
| LOW | deny.toml | 101 | ] | COMMENT |
| LOW | deny.toml | 121 | # The SPDX expression for the license requirements of the crate | COMMENT |
| LOW | deny.toml | 141 | # not have its license(s) checked | COMMENT |
| LOW | deny.toml | 161 | # the workspace that is being checked. This can be overridden by allowing/denying | COMMENT |
| LOW | deny.toml | 181 | COMMENT | |
| LOW | deny.toml | 201 | # If true, the allowed features must exactly match the enabled feature set. If | COMMENT |
| LOW | deny.toml | 221 | # https://embarkstudios.github.io/cargo-deny/checks/sources/cfg.html | COMMENT |
| LOW | clap_derive/src/lib.rs | 1 | // Copyright 2018 Guillaume Pinot (@TeXitoi) <texitoi@texitoi.eu>, | COMMENT |
| LOW | clap_derive/src/item.rs | 1 | // Copyright 2018 Guillaume Pinot (@TeXitoi) <texitoi@texitoi.eu>, | COMMENT |
| LOW | clap_derive/src/utils/doc_comments.rs | 1 | //! The preprocessing we apply to doc comments. | COMMENT |
| LOW | clap_derive/src/derives/into_app.rs | 1 | // Copyright 2018 Guillaume Pinot (@TeXitoi) <texitoi@texitoi.eu>, | COMMENT |
| LOW | clap_derive/src/derives/mod.rs | 1 | // Copyright 2018 Guillaume Pinot (@TeXitoi) <texitoi@texitoi.eu>, | COMMENT |
| LOW | clap_derive/src/derives/subcommand.rs | 1 | // Copyright 2018 Guillaume Pinot (@TeXitoi) <texitoi@texitoi.eu>, | COMMENT |
| LOW | clap_derive/src/derives/args.rs | 1 | // Copyright 2018 Guillaume Pinot (@TeXitoi) <texitoi@texitoi.eu>, | COMMENT |
| LOW | clap_derive/src/derives/parser.rs | 1 | // Copyright 2018 Guillaume Pinot (@TeXitoi) <texitoi@texitoi.eu>, | COMMENT |
| LOW | clap_complete/examples/completion-derive.rs | 1 | //! How to use value hints and generate shell completions. | COMMENT |
| LOW | clap_complete/examples/completion.rs | 1 | //! Example to test arguments with different `ValueHint` values. | COMMENT |
| LOW | clap_complete/src/lib.rs | 1 | // Copyright ⓒ 2015-2018 Kevin B. Knapp | COMMENT |
| LOW | clap_complete/src/lib.rs | 21 | //! use std::io; | COMMENT |
| LOW | clap_complete/src/lib.rs | 41 | //! let mut cmd = build_cli(); | COMMENT |
| LOW | clap_complete/src/engine/custom.rs | 21 | /// let mut completions = vec![]; | COMMENT |
| LOW | clap_complete/src/engine/custom.rs | 61 | } | COMMENT |
| LOW | clap_complete/src/engine/custom.rs | 121 | } | COMMENT |
| LOW | clap_complete/src/engine/custom.rs | 241 | COMMENT | |
| LOW | clap_complete/src/aot/mod.rs | 1 | //! Prebuilt completions | COMMENT |
| LOW | clap_complete/src/aot/mod.rs | 21 | //! | COMMENT |
| LOW | clap_complete/src/aot/shells/zsh.rs | 61 | } | COMMENT |
| LOW | clap_complete/src/aot/shells/zsh.rs | 81 | // (( $+functions[_rustup_commands] )) || | COMMENT |
| LOW | clap_complete/src/aot/shells/zsh.rs | 141 | } | COMMENT |
| LOW | clap_complete/src/aot/shells/zsh.rs | 181 | COMMENT | |
| LOW | clap_complete/src/aot/shells/zsh.rs | 201 | // ([name]) | COMMENT |
| LOW | clap_complete/src/aot/shells/zsh.rs | 301 | None | COMMENT |
| LOW | clap_complete/src/aot/shells/zsh.rs | 601 | } | COMMENT |
| LOW | clap_complete/src/aot/shells/shell.rs | 101 | /// Parse a shell from a path to the executable for the shell | COMMENT |
| LOW | clap_complete/src/aot/shells/shell.rs | 121 | /// | COMMENT |
| LOW | clap_complete/src/aot/shells/fish.rs | 81 | // example : | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 21 | /// # Examples | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 41 | /// | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 61 | /// # } | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 81 | /// use std::{io::{Error, Write}, fmt::write}; | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 101 | Ok(()) | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 121 | /// First, it helps if we separate out our `Command` definition into a separate file. Whether you | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 141 | /// In our regular code, we can simply call this `build_cli()` function, then call | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 161 | /// clap = "*" | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 181 | /// | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 201 | /// **NOTE:** Please look at the individual [shells][crate::shells] | COMMENT |
| LOW | clap_complete/src/aot/generator/mod.rs | 261 | /// we can let users generate a completion script using a command: | COMMENT |
| LOW | clap_lex/src/lib.rs | 1 | //! Minimal, flexible command-line parser | COMMENT |
| LOW | clap_lex/src/lib.rs | 21 | //! | COMMENT |
| LOW | clap_lex/src/lib.rs | 41 | //! } | COMMENT |
| LOW | clap_lex/src/lib.rs | 61 | //! while let Some(arg) = raw.next(&mut cursor) { | COMMENT |
| LOW | clap_lex/src/lib.rs | 81 | //! } | COMMENT |
| LOW | clap_lex/src/lib.rs | 101 | //! } else { | COMMENT |
| LOW | clap_lex/src/lib.rs | 141 | /// | COMMENT |
| LOW | clap_lex/src/lib.rs | 161 | /// ```rust,no_run | COMMENT |
| LOW | clap_lex/src/lib.rs | 361 | COMMENT | |
| 715 more matches not shown… | ||||
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | tests/derive/doc_comments_help.rs | 24 | /// Lorem ipsum | COMMENT |
| LOW | tests/derive/doc_comments_help.rs | 35 | Lorem ipsum | CODE |
| LOW⚡ | tests/derive/doc_comments_help.rs | 51 | /// Lorem ipsum | COMMENT |
| LOW⚡ | tests/derive/doc_comments_help.rs | 53 | #[command(name = "lorem-ipsum", about = "Dolor sit amet")] | COMMENT |
| LOW⚡ | tests/derive/doc_comments_help.rs | 62 | Dolor sit amet | CODE |
| LOW | tests/derive/doc_comments_help.rs | 98 | /// Lorem ipsumclap | COMMENT |
| LOW | tests/derive/doc_comments_help.rs | 100 | #[command(name = "lorem-ipsum", about = "Dolor sit amet")] | COMMENT |
| LOW | tests/derive/doc_comments_help.rs | 117 | Dolor sit amet | CODE |
| LOW | tests/derive/doc_comments_help.rs | 128 | Dolor sit amet | CODE |
| LOW | tests/derive/doc_comments_help.rs | 149 | /// Lorem ipsumclap | COMMENT |
| LOW | tests/derive/doc_comments_help.rs | 151 | #[command(name = "lorem-ipsum", about = "Dolor sit amet")] | COMMENT |
| LOW | tests/derive/doc_comments_help.rs | 172 | Dolor sit amet | CODE |
| LOW | tests/derive/doc_comments_help.rs | 457 | /// Lorem ipsum | COMMENT |
| LOW | tests/derive/doc_comments_help.rs | 468 | Lorem ipsum | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| HIGH | tests/ui/help_cmd_stdout.toml | 0 | usage: stdio-fixture[exe] [options] [name] [env] [command] commands: more test subcommand with one visible alias [alias: | STRING |
| HIGH | tests/ui/help_flag_stdout.toml | 0 | usage: stdio-fixture[exe] [options] [name] [env] [command] commands: more test subcommand with one visible alias [alias: | STRING |
| HIGH | tests/ui/h_flag_stdout.toml | 0 | usage: stdio-fixture[exe] [options] [name] [env] [command] commands: more test subcommand with one visible alias [alias: | STRING |
| HIGH | tests/ui/arg_required_else_help_stderr.toml | 0 | usage: stdio-fixture[exe] [options] [name] [env] [command] commands: more test subcommand with one visible alias [alias: | STRING |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | src/_derive/mod.rs | 359 | //! #[command(about = "I am a program and I work, just pass `-h`", long_about = None)] | COMMENT |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | .github/workflows/release-notes.py | 4 | CODE |
| Severity | File | Line | Snippet | Context |
|---|---|---|---|---|
| LOW | .github/workflows/release-notes.py | 12 | CODE |