diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-05-29 14:24:25 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-05-29 14:24:25 +0800 |
| commit | 23930c24b7eaf519d8ed36e4f433790eeb4d07fb (patch) | |
| tree | 06540a1018c5b7070dc96c50141d49842c74778e /mingling_macros/src/dispatcher_clap.rs | |
| parent | dccc86be272091f4f14be52951f8c02996318cd0 (diff) | |
Update docs and examples for clap binding with optional error parameter
Diffstat (limited to 'mingling_macros/src/dispatcher_clap.rs')
| -rw-r--r-- | mingling_macros/src/dispatcher_clap.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/mingling_macros/src/dispatcher_clap.rs b/mingling_macros/src/dispatcher_clap.rs index 8ef2125..5a6cf4c 100644 --- a/mingling_macros/src/dispatcher_clap.rs +++ b/mingling_macros/src/dispatcher_clap.rs @@ -23,6 +23,11 @@ impl Parse for ClapOptions { // Parse leading comma input.parse::<Token![,]>()?; + // Allow trailing comma + if input.is_empty() { + break; + } + let key: Ident = input.parse()?; input.parse::<Token![=]>()?; |
