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
Optparse hanging infinitely & support for multiple usage of the same flag #58
Comments
It is possible, but you can't repeat an option with a default value, because in that case you get an infinite list as a result, and that makes the parser diverge. Just remove |
Thank you very much! I'm sorry for posting an incorrect bug report. 2013/11/19 Paolo Capriotti notifications@github.com
|
i stumbled upon this same problem today. i tried a clumsy |
actually the best solution would probably be a function like |
it could be modified as in #295 but it's not very visible, maybe we could have some examples of this usage elsewhere, or point to a guide which goes through applicative parsing? |
Hi!
Would it be possible to add support for multiple usage of the same flag?
I would love to allow users to use arguments like this
myprog --dump ast --dump va --dump test
and I would like to get array of String's as a result.And here is what I was trying (what was natural to me, because I have some Parsec background) and it hanged optparse when printing help:
[...] many (strOption (long "dump" <> value "" <> metavar "DUMP")) [...]
Thank you.
The text was updated successfully, but these errors were encountered: