Commit 26058b5b authored by Kirill Smelkov's avatar Kirill Smelkov

gpython: Factor-out options parsing into getopt-style _IGetOpt helper

Python allows multiple single-letter options and their arguments to be
coming on single argument, for example:

	python -OQc'print 1'
	python -OQc 'print 1'
	python -OQ -c 'print 1'
	etc...

We are currently trying to handle that at every option, but even though
it kind of works, it is limited and will break once we will start adding
options.

-> Refactor options parsing into getopt-style helper. We cannot use
getopt itself because it will complain e.g. on `gpython file.py
--my-custom-opt` that my-custom-opt is unexpected.
parent 167912d3
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment