ó œt•Pc@sAddlZddlZddlmZd„Zed„ZdS(i˙˙˙˙N(t_c Csg}d|kr<|jdƒ}||d}|| }ntj|||ƒ\}}g}xŒ|rë|jdƒ}|rŰ|ddkrŰt|ƒdkrŰ|jd|ƒtj|||ƒ\}} ||}| }q`|j|ƒq`W|j|ƒ||fS(sşParse options mostly like getopt.gnu_getopt. This is different from getopt.gnu_getopt in that an argument of - will become an argument of - instead of vanishing completely. s--iit-(tindextgetopttpoptlentinserttappendtextend( targstoptionst longoptionst extraargst stopindextoptst parseargstargttoptst newparseargs((s7/sys/lib/python2.7/site-packages/mercurial/fancyopts.pyt gnugetopt s"   (   cCs˝g}d}i}i}xB|D]:}t|ƒdkrO|\} } } } } n|\} } } } | }| jddƒ} | |d| <|d|<| || s