# HG changeset patch # User mpm@selenic.com # Date 1124506580 28800 # Node ID 0aaeee519c66a6a648836218629528e5b878b322 # Parent d845a1f174bb2b4146d28157acb343d9fb5039c0 Fix option parsing bug for empty short options diff -r d845a1f174bb -r 0aaeee519c66 mercurial/fancyopts.py --- a/mercurial/fancyopts.py Fri Aug 19 18:47:05 2005 -0800 +++ b/mercurial/fancyopts.py Fri Aug 19 18:56:20 2005 -0800 @@ -10,7 +10,9 @@ map['-'+s] = map['--'+l]=l state[l] = d dt[l] = type(d) - if not d is None and not callable(d): s, l=s+':', l+'=' + if not d is None and not callable(d): + if s: s += ':' + if l: l += '=' if s: short = short + s if l: long.append(l)