diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-07-16 18:58:31 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-07-16 19:04:10 +0800 |
| commit | 41fe0580212b3a681fd767d331fd8875ee59b019 (patch) | |
| tree | 4032d50ecbcb1d7ce566012ade310b00a3b3d921 /mingling_picker/src/picker/parse.rs | |
| parent | 7ab6216fd2c056ef0c155f37e4c95df90b88701c (diff) | |
feat(picker): add `Flag` value type and `Pickable` implementation
Add a new `Flag` enum in `mingling_picker::value` that explicitly
distinguishes between an absent flag (`Inactive`) and a present flag
(`Active`), along with its `Pickable` implementation. Rename internal
fields from `flag_*` to `arg_*` for consistency, update the default
naming case to `Kebab`, and enable the `mingling_support` feature in
workspace settings.
Diffstat (limited to 'mingling_picker/src/picker/parse.rs')
| -rw-r--r-- | mingling_picker/src/picker/parse.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/mingling_picker/src/picker/parse.rs b/mingling_picker/src/picker/parse.rs index 69de583..8f7d514 100644 --- a/mingling_picker/src/picker/parse.rs +++ b/mingling_picker/src/picker/parse.rs @@ -67,13 +67,13 @@ internal_repeat!(1..=32 => { // ArgInfos let arg_infos: [PickerArgInfo; $] = [ ( - PickerArgInfo::from(self.flag_$), + PickerArgInfo::from(self.arg_$), +) ]; let mut bundle: [ ( - // Flag Attr + // Arg Attr PickerArgAttr, // Tag Func @@ -88,8 +88,8 @@ internal_repeat!(1..=32 => { ; $] = [ ( ( - // Flag Attr - T$::get_attr(self.flag_$), + // Arg Attr + T$::get_attr(self.arg_$), // Tag Func Box::new(|args, mask| { @@ -143,7 +143,7 @@ internal_repeat!(1..=32 => { // Sort by Bundle Ord (descending) bundle.sort_by(|a, b| b.0.cmp(&a.0)); - // Mask — size = number of args (not flags), so use args length + // Mask — size = number of args (not args), so use args length let mut mask: Vec<u8> = vec![0u8; self.args.len()]; // Parsing |
