Message184425
| Author |
paul.j3 |
| Recipients |
Christophe.Guillon, abacabadabacaba, amcnabb, andersk, bethard, danielsh, davidben, drm, eric.araujo, eric.smith, gdb, gfxmonk, nelhage, paul.j3, r.david.murray, skilletaudio |
| Date |
2013年03月18日.05:45:12 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1363585512.77.0.420234166761.issue9334@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
I think the `re.compile(r'^-.+$')` behavior could be better achieved by inserting a simple test in `_parse_optional` before the `_negative_number_matcher` test.
# behave more like optparse even if the argument looks like a option
if self.args_default_to_positional:
return None
In effect, if the string does not match an action string, say it is a positional.
Making this patch to argparse.py is simple. How much to test it, and how document it requires more thought. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2013年03月18日 05:45:13 | paul.j3 | set | recipients:
+ paul.j3, amcnabb, bethard, eric.smith, eric.araujo, r.david.murray, gfxmonk, andersk, abacabadabacaba, gdb, nelhage, drm, davidben, skilletaudio, Christophe.Guillon, danielsh |
| 2013年03月18日 05:45:12 | paul.j3 | set | messageid: <1363585512.77.0.420234166761.issue9334@psf.upfronthosting.co.za> |
| 2013年03月18日 05:45:12 | paul.j3 | link | issue9334 messages |
| 2013年03月18日 05:45:12 | paul.j3 | create |
|