Skip to content
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

Add cond_opt #1553

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Add cond_opt #1553

wants to merge 1 commit into from

Conversation

KoltesDigital
Copy link

cond takes a bool and a Parser. This patch adds cond_opt which does the same with a single Option<Parser>. Implementation and example are also based on cond.

I found it would be useful in one of my projects where a trait method returns an Option<Parser>.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant