-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow groups of groups #5711
Comments
I've been looking into this a bit more. Are you sure there are still "debug assertions to make sure the Id is a valid Arg or Group Id" in the project? Grepping for Variable naming is a bit biased, "arg" is everywhere around those methods even if it is explicitly checked against group_ids as well. Renaming the method(s) on Edit: |
I'm a bit confused. You pointed at code in If I look in clap/clap_builder/src/builder/debug_asserts.rs Lines 290 to 299 in 64e3790
which is the latest commit for master https://github.com/clap-rs/clap/blob/master/clap_builder/src/builder/debug_asserts.rs#L290-L299 that code is not there. This matches the behavior you saw in #5700 (comment) |
Oh my that happens when you start off with existing work and mess up your rebase. So those lines 290 - 300 were my changes from investigating the original subgroups approach. |
A blocker for #4697 which is important for #3123 and #2621 is the ability to have a group own another group.
API-wise, I suspect we'd change
ArgGroup::arg
toArgGroup::member
orArgGroup::child
to generalize it for taking either an arg or a group ID.To unblock this, we'd need to update the debug assertions to make sure the
Id
is a valid Arg or GroupId
.There is also the validation work
The text was updated successfully, but these errors were encountered: