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

Positional arguments? #46

Open
tripulse opened this issue Jul 23, 2021 · 2 comments
Open

Positional arguments? #46

tripulse opened this issue Jul 23, 2021 · 2 comments

Comments

@tripulse
Copy link

The feature section on the README talks about positional arguments but no example has been shown and I can't find how it can be done even after reading the code.

@cofyc
Copy link
Owner

cofyc commented Jul 23, 2021

positional arguments are remainder arguments after all positional optional arguments are processed and removed, see the example code here

@tripulse
Copy link
Author

tripulse commented Jul 23, 2021

after all positional arguments are processed and removed

you mean optional arguments, right?

@cofyc
Copy link
Owner

cofyc commented Jul 23, 2021

yes, my typo

@tripulse
Copy link
Author

oh okay

@tripulse
Copy link
Author

but you have to parse the value types manually, wouldn't it be more easier that we specify positonals in the argparse_option array so it takes care of it.

@tripulse tripulse reopened this Jul 23, 2021
@tripulse
Copy link
Author

but wait, that modifies a const char**

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

No branches or pull requests

2 participants