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

parse(): support both const char **argv and char **argv interface version #62

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

Conversation

GerHobbelt
Copy link

parse(): support both const char **argv and char **argv interface version.

Some codebase have argv as const char **argv or const char *argv[] while others have it without the const modifier. This takes care of that and makes clipp a drop-in for both styles.

(cherrypicked off https://github.com/GerHobbelt/clipp master branch; original commit tested with latest MSVC2019)

@chirsz-ever
Copy link

Maybe changing char* argv[] to const char* const* argv is enough. Non-const arguments would be auto converted to const type.

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.

None yet

2 participants