
    6hge             	         S SK Jr  S SKrS SKrS SKrS SKrSSKJr  SSKJ	r	J
r
Jr  SSKJrJrJrJrJrJrJrJrJrJrJrJrJrJrJrJrJ r J!r!J"r#J$r$  SSK%J&r&J'r'J(r(  \RR                  r)\RT                  r*\RV                  r+\RX                  r,\RZ                  r-\R\                  r.\R^                  r/\R`                  r0\!Rb                  r1\!Rd                  r2\!Rf                  r3\!Rh                  r4\
\4r5Sr6S	r7S
r8\74S jr9S r:S r;S r<S r=S r>S r?S r@S rAS rBS rCS rDS rES rFS rGS rHS rIS rJS rKS rLS rMS  rNS! rOS" rPS# rQS$ rRS% rSS& rT\R                  rU\V" 5       rW\R                  " 5       rY\Y" S'5      S( 5       rZ\Y" S)5      S* 5       r[\Y" S+S,S-S.9S/ 5       r\\Y" S0S,S1S.9S2 5       r] GSS4 jr^\Y" S5S,S69S7 5       r_\Y" S8S,S69S9 5       r`S: raS; rb\Y" S<S,S=S.9S> 5       rc\Y" S?S,S69S@ 5       rd\Y" SAS,S69SB 5       re\Y" SCS,S69SD 5       rf\Y" SES,S=S.9SF 5       rg\Y" SGS,S69SH 5       rh\Y" SIS,S69SJ 5       riSK rjSL rk\Y" SMS,S69SN 5       rl\Y" SOS,S=S.9SP 5       rm\Y" SQS,S69SR 5       rn\Y" SSS,S69ST 5       ro\Y" SUS,S69SV 5       rp\Y" SWS,S69SX 5       rq\Y" SYSZS[9S\ 5       rr\Y" S]S,S69S^ 5       rs\Y" S_S,S=S.9S` 5       rt\Y" SaS,S=S.9Sb 5       ru GSSc jrv\Y" SdS,S69Se 5       rw\Y" SfS,S69Sg 5       rx\Y" ShS,S=S.9Si 5       ry\Y" SjSkS[9Sl 5       rz\Y" SmS,S69Sn 5       r{\Y" SoS,S,Sp9Sq 5       r|\Y" SrS3SZS.9Ss 5       r}\Y" StS,S69Su 5       r~\Y" SvS,S69Sw 5       r\Y" SxS,S69Sy 5       r\Y" SzS,S,S S{9S| 5       rGSS} jr\Y" S~S,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" S5      S 5       r\Y" SS,S69S 5       r\Y" SS=S[9S 5       r\Y" SS,S69S 5       r\Y" SS,S=S.9S 5       r\Y" SS,S69S 5       r\Y" SS,S,Sp9S 5       r\Y" SS,S69S 5       r\Y" SS,S=S.9S 5       r\Y" SS,S,S S{9S 5       r\Y" SS,S,Sp9S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S-S.9S 5       r\Y" S5      S 5       rS r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS3S=S.9S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       rS r\Y" SS,S69S 5       rS r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r"S r\Y" SS,S,Sp9S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS3S69S 5       r\Y" SS,S-S.9S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S,Sp9S 5       rX\Y" SS,S69S 5       r\Y" SS,S,S S{9S 5       r\Y" SS,S69S 5       rSr\* S-
  r\4S jr\ GRh                  S S S S S \ GRj                  \S.rS r\Y" SS,S,S=S{9S 5       r\Y" S5      S 5       rS r\Y" SS,S69S 5       rGSS jr\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S69S 5       r\Y" SS,S=S.9S 5       r\Y" SS,S S.9S 5       rS r\Y" SS,S,Sp9S 5       rS r\Y" SS,S,S S{9GS  5       rGS r\Y" GSS,S,Sp9GS 5       r0 GS\@_GS\A_GS\B_GS\C_GS\E_GS	\<_GS
\<_GS\F_GS\G_GS\J_GS\K_GS\H_GS\L_GS\P_GS\Q_GS\R_GS\S_\T\b\\\=\>GS.Er\N\NGS.r\O\OGS.rGS rGSGS jrGS GS jrGS rGS r\" SS\Y5        \UGR                  5       rg(!      )annotationsN   )_)binnullrevwdirrev)dagopdestutildiffutilencodingerrorgrephbisectmatchobsoleteobsutilpathutilphasespycompat	registrarrepoview
revsetlangscmutilsmartsetstackutil)dateutil
stringutilurlutils   anys   define   followc                    U(       d  [         R                  " [        S5      5      e[        US      " X/USS  Q7SU06$ )Ns   missing argumentr   r   order)r   
ParseErrorr   methodsreposubsetxr"   s       2/usr/lib/python3/dist-packages/mercurial/revset.pygetsetr*   p   s?    q!45661Q4=;!";U;;    c                    X   R                  5       nS H   nX2;   d  M
   XU      R                  5       s  $    g ! [        R                   a     M<  f = f)N)   sources   transplant_sources   rebase_source)extrarevr   RepoLookupError)r&   rr.   labels       r)   _getrevsourcer3   v   sY    GMMOED>%L)--// E  (( s   :AAc                ^    [        [        R                  " [        R                  U 5      5      $ N)sortedr   rapplymaybebytestr)xss    r)   _sortedbr:      s    (//("7"7<==r+   c                   U(       d  [         R                  " [        S5      5      e[        R                  " [        R
                  " X5      5      nX!;   d  U[        ;   a!  [        U[        5      (       a  [        U/5      $ [        5       $ )Ns$   empty string is not a valid revision)
r   r#   r   r   intrev	revsymbol_virtualrevs
isinstancefullreposetbasesetr%   s       r)   	stringsetrB      sa    q!HIJJw((12A{a<'Jv{,K,Ks|9r+   c                &    U[         :X  a  X-  $ X!-  $ )z1argument is already a smartset, use that directly)followorderr%   s       r)   rawsmartsetrE      s    zzr+   c                <    [        X5      nU[        :X  a  X-  $ XA-  $ )z2argument is a list of nodeid, resolve and use them)_ordered_node_setrD   )r&   r'   r(   r"   nodess        r)   raw_node_setrI      s$    d&E~~r+   c                    U(       d
  [        5       $ U R                  R                  R                  n[        U Vs/ s H
  o2" U5      PM     sn5      $ s  snf r5   )rA   	changelogindexr/   )r&   rH   to_revr1   s       r)   rG   rG      sC    y^^!!%%Fu-u!F1Iu-..-s   Ac                    [        U [        U 5      U5      n[        U [        U 5      U5      nU(       a  U(       d
  [        5       $ [        XUR	                  5       UR                  5       U5      $ r5   )r*   r@   rA   _makerangesetfirstlast)r&   r'   r(   yr"   mns          r)   rangesetrU      sR    t[&*At[&*AAyqwwy!&&(EBBr+   c                X    Ub   e[        XSU R                  R                  5       U5      $ Nr   )rO   rK   tiprevr%   s       r)   rangeallrY      s*    99q$..*?*?*A5IIr+   c                    [        U [        U 5      U5      nU(       d
  [        5       $ [        XSUR	                  5       U5      $ rW   )r*   r@   rA   rO   rQ   )r&   r'   rR   r"   rT   s        r)   rangeprer[      s7    t[&*Ayq!&&(E::r+   c                    [        U [        U 5      U5      nU(       d
  [        5       $ [        XUR	                  5       U R
                  R                  5       U5      $ r5   )r*   r@   rA   rO   rP   rK   rX   )r&   r'   r(   r"   rS   s        r)   	rangepostr]      sI    t[&*Ayaggi!6!6!8% r+   c                j   X#:X  a  [        U/5      nOU[        :X  a#  [        X[        U 5      5      [        U/5      -   nOcU[        :X  a5  [        U/5      [        X R                  R                  5       US-
  5      -   nO$X#:  a  [        XUS-   5      nO[        XUS-
  5      nU[        :X  a  XQ-  $ X-  $ Nr   )rA   r   spansetlenrK   rX   defineorder)r&   r'   rS   rT   r"   r1   s         r)   rO   rO      s    vQCL	
gDSY''1#,6	
gQCL74)>)>)@!a%HH	
DQU#DQU#z zr+   c           	     v    [        U 5      n[        R                  " U [        XU5      [        XU5      SS9nX-  $ )NT)includepath)r@   r	   reachablerootsr*   )r&   r'   r(   rR   r"   r1   r9   s          r)   dagrangerf      s=    DA			fTa &!"4$
B ;r+   c           	     ^    U[         :X  a  [         nO[        n[        U [        XX$5      X55      $ r5   anyorderrD   r*   r&   r'   r(   rR   r"   yorders         r)   andsetrl      s*    $tQ6BBr+   c           	     ^    U[         :X  a  [         nO[        n[        U [        XX55      X$5      $ r5   rh   rj   s         r)   andsmallysetrn      s*    $tQ7BBr+   c                >    [        XX$5      [        XU[        5      -
  $ r5   r*   ri   r&   r'   r(   rR   r"   s        r)   differencesetrr      s    $)F4H,MMMr+   c                    U(       d   e[        U5      S:X  a  [        XUS   U5      $ [        U5      S-  n[        XUS U U5      n[        XX$S  U5      nXV-   $ )Nr   r      )ra   r*   
_orsetlist)r&   r'   r9   r"   pabs          r)   ru   ru      sa    I2
2w!|dBqE511B1A4BQ/A4B/A5Lr+   c                    [        U5      nU(       d
  [        5       $ U[        :X  a  U[        U [	        U 5      U[
        5      -  $ [        XXC5      $ r5   )getlistrA   rD   ru   r@   ri   )r&   r'   r(   r"   r9   s        r)   orsetr{     sF    	By
4T):BIII$22r+   c                *    U[        XU[        5      -
  $ r5   rp   r%   s       r)   notsetr}     s    F4H555r+   c                    [        U5      nU[        ;   a  [        U   " XX%U5      $ [        R                  5        Vs/ s H  n[        U5      S:  d  M  UPM     nn[        R
                  " XW5      es  snf r_   )	getsymbol	relationskeysra   r   UnknownIdentifier)r&   r'   r(   rR   r"   relr1   relnamess           r)   relationsetr     se     A,C
i~dAE::$>>+:+as1vz+H:

!
!#
00 ;   A2A2c                    SnSnXs=:X  a  S:X  a  O  OSnU S:  a  [        US5      * U * S-   4nUS:  a  [        U S5      US-   4nX#4$ )a^  Split range with bounds a and b into two ranges at 0 and return two
tuples of numbers for use as startdepth and stopdepth arguments of
revancestors and revdescendants.

>>> _splitrange(-10, -5)     # [-10:-5]
((5, 11), (None, None))
>>> _splitrange(5, 10)       # [5:10]
((None, None), (5, 11))
>>> _splitrange(-10, 10)     # [-10:10]
((0, 11), (0, 11))
>>> _splitrange(-10, 0)      # [-10:0]
((0, 11), (None, None))
>>> _splitrange(0, 10)       # [0:10]
((None, None), (0, 11))
>>> _splitrange(0, 0)        # [0:0]
((0, 1), (None, None))
>>> _splitrange(1, -1)       # [1:-1]
((None, None), (None, None))
NNr   )r   r   r   )minmax)rw   rx   	ancdepths
descdepthss       r)   _splitranger     s_    ( IJ{{	1u!QiZ!a(	1u!QiQ'
  r+   c                     Sn[        XX#XT5      $ )N)   rangeallN)generationssubrel)r&   r'   r(   r   r"   zs         r)   generationsrelr   <  s    AT11<<r+   c                   [        U[        S5      [        S5      [        R                  S-
  * [        R                  S-
  7S9u  pg[	        Xg5      u  u  pu  pUc  U
c
  [        5       $ [        U [        U 5      U5      nU(       d
  [        5       $ Ub:  U
b7  [        R                  " XSX5      nU[        R                  " XSX5      -  nX-  $ Ub  [        R                  " XSX5      nX-  $ U
b  [        R                  " XSX5      nUW-  $ )Ns0   relation subscript must be an integer or a ranges*   relation subscript bounds must be integersr   )deffirstdeflastF)
getintranger   r	   maxlogdepthr   rA   r*   r@   revancestorsrevdescendants)r&   r'   r(   r   r   r"   rw   rx   ancstartancstop	descstartdescstoprevsss                 r)   r   r   A  s    		
=>	
78$$q()##a'(DA 2=Q1B.X.)I-y$D)1-Dy	 5t5(D	U!!$eYII : 
	t5(D : 
	  UIHA:r+   c                    [        U5      nU[        ;   a  [        U   " XX&XE5      $ [        R                  5        Vs/ s H  n[        U5      S:  d  M  UPM     nn[        R
                  " Xh5      es  snf r_   )r   subscriptrelationsr   ra   r   r   )	r&   r'   r(   rR   r   r"   r   r1   r   s	            r)   relsubscriptsetr   _  sj     A,C
  !#&tQQFF-224C4aA
4HC

!
!#
00 Dr   c                @    [         R                  " [        S5      5      e)Ns%   can't use a subscript in this contextr   r#   r   rq   s        r)   subscriptsetr   k  s    


1EF
GGr+   c                P    [         R                  " [        S5      [        S5      S9e)Ns    can't use a list in this contexts   see 'hg help "revsets.x or y"')hintr   )r&   r'   r9   optss       r)   listsetr   o  s'    


	
-.23 r+   c                @    [         R                  " [        S5      5      e)Ns*   can't use a key-value pair in this contextr   )r&   r'   kvr"   s        r)   keyvaluepairr   v  s    


1JK
LLr+   c                2   [        U5      nU[        ;   a-  [        U   n[        USS5      (       a	  U" XX45      $ U" XU5      $ S n[        R                  5        VV	s/ s H  u  pU" U	5      (       d  M  UPM     n
nn	[        R
                  " XZ5      es  sn	nf )N
_takeorderFc                     [        U SS 5      S L$ )N__doc__)getattr)fns    r)   <lambda>func.<locals>.<lambda>  s    gb)T2$>r+   )r   symbolsr   itemsr   r   )r&   r'   rw   rx   r"   ffunckeepr   r   symss              r)   r   r   z  s    !AG|qz4u--a//D!$$>D$]]_9_'1RA_D9

!
!!
** :s   B4Bs   _destupdatec           
         [        USS5      nU[        [        R                  " U 40 [        R
                  " U5      D6S   /5      -  $ )N   limits   cleanr   )getargsdictrA   r
   
destupdater   	strkwargs)r&   r'   r(   argss       r)   _destupdater     sL     q(H-DG			T	>X%7%7%=	>q	AB  r+   s
   _destmergec                z    S nUb  [        U [        U 5      U5      nU[        [        R                  " XS9/5      -  $ )N)	sourceset)r*   r@   rA   r
   	destmerge)r&   r'   r(   r   s       r)   
_destmerger     s?     I}4T!2A6	GX//JKLLLr+   s   adds(pattern)T   )safeweightc                F    [        U[        S5      5      n[        XUS5      $ )zChangesets that add a file matching pattern.

The pattern without explicit kind like ``glob:`` is expected to be
relative to the current directory and match against a file or a
directory.
s   adds requires a patternadded	getstringr   checkstatusr&   r'   r(   pats       r)   addsr     s%     Aq34
5CtS'22r+   s   ancestor(*changeset)g      ?c           	     2   [        [        U [        U 5      U[        S95      n U [	        U5         nU H  nUR                  X   5      nM     [        R                  " U5      nXQ;   a  [        U/5      $ [        5       $ ! [
         a    [        5       s $ f = f)zA greatest common ancestor of the changesets.

Accepts 0 or more changesets.
Will return empty list when passed no args.
Greatest common ancestor of a single changeset is that changeset.
r"   )
iterr{   r@   ri   nextStopIterationrA   ancestorr   r<   )r&   r'   r(   reviterancr1   s         r)   r   r     s     5{40!8DEG4=! ll47#  	sA{s|9  ys   A? ?BBFc                    [        U [        U 5      U5      nU(       d
  [        5       $ [        R                  " XX4U5      nX-  $ r5   )r*   r@   rA   r	   r   )r&   r'   r(   followfirst
startdepth	stopdepthheadsr   s           r)   
_ancestorsr     s>     4T*A.Ey4KA:r+   s   ancestors(set[, depth]))r   c                ~   [        USS5      nSU;  a  [        R                  " [        S5      5      eS=pESU;   a-  [	        US   S5      nUS:  a  [        R                  " S	5      eUnS
U;   aB  [	        US
   [        S5      5      nUS:  a  [        R                  " [        S5      5      eUS-   n[        XUS   XES9$ )zChangesets that are ancestors of changesets in set, including the
given changesets themselves.

If depth is specified, the result only includes changesets up to
the specified generation.
s	   ancestors   set depth startdepth   sets#   ancestors takes at least 1 argumentN
   startdepths'   ancestors expects an integer startdepthr      negative startdepth   depths"   ancestors expects an integer depth   negative depthr   r   r   )r   r   r#   r   
getintegerr   r&   r'   r(   r   r   r   rT   s          r)   	ancestorsr     s     q,(?@DTq!GHII!!J!K
 q5""#9::
4tH~q)N'OPq5""1%6#788E	d6lz r+   s   _firstancestorsc                    [        XUSS9$ NTr   )r   r&   r'   r(   s      r)   _firstancestorsr     s     dA488r+   c                h   [        5       n[        U [        U 5      U5       H  n[        U5       Hh  nX   R	                  5       n[        U5      S:X  a    M5  [        U5      S:  a  [        R                  " [        S5      5      eUS   R                  5       nMj     UR                  U5        M     X-  $ )z9Changesets that are the Nth child of a changeset
in set.
r   r   s'   revision in set has more than one child)setr*   r@   rangechildrenra   r   r0   r   r/   add)	r&   r'   r(   rT   r"   csr1   ics	            r)   _childrenspecr      s     
BD+d+Q/qA  "A1v{1vz++@A  !
A  FF1I 0 ;r+   c                   [        U[        S5      5      nUS:  a  [        XX#* U5      $ [        5       nU R                  n[        U [        U 5      U5       H;  n[        U5       H  n UR                  U5      S   nM     UR                  U5        M=     X-  $ ! [        R                   a$    X   R                  5       R                  5       n Ml  f = f)z[``set~n``
Changesets that are the Nth ancestor (first parents only) of a changeset
in set.
s   ~ expects a numberr   )r   r   r   r   rK   r*   r@   r   
parentrevsr   WdirUnsupportedp1r/   r   )	r&   r'   r(   rT   r"   psclr1   r   s	            r)   ancestorspecr     s    
 	1a-./A1uT1b%88	B	BD+d+Q/qA'MM!$Q' 
 	q	 0 ; (( 'GJJL$$&'s   (B4CCs   author(string)
   c                x   ^ ^ [        U[        S5      5      n[        USS9u  pEmUR                  UU 4S jSU4S9$ )zAlias for ``user(string)``.s   author requires a stringFcasesensitivec                6   > T" TU    R                  5       5      $ r5   user)r(   matcherr&   s    r)   r   author.<locals>.<lambda>0  s    '$q',,.)r+   s	   <user %r>condreprr   r   _substringmatcherfilter)r&   r'   r(   rT   kindpatternr  s   `     @r)   authorr  )  sH     	!Q234A.qFD7==)\14E   r+   s   bisect(string)c                    [        U[        S5      5      R                  5       n[        [        R
                  " X5      5      nX-  $ )a  Changesets marked in the specified bisect status:

- ``good``, ``bad``, ``skip``: csets explicitly marked as good/bad/skip
- ``goods``, ``bads``      : csets topologically good/bad
- ``range``              : csets taking part in the bisection
- ``pruned``             : csets that are goods, bads or skipped
- ``untested``           : csets whose fate is yet unknown
- ``ignored``            : csets ignored due to DAG topology
- ``current``            : the cset currently being bisected
s   bisect requires a string)r   r   lowerr   r   get)r&   r'   r(   statusstates        r)   bisectr  4  s:     q!789??AFD)*E>r+   s   bisectedc                    [        XU5      $ r5   )r  r   s      r)   bisectedr  H  s    $""r+   s   bookmark([name])c                Z   [        USS[        S5      5      nU(       Ga@  [        US   [        S5      5      n[        R                  " U5      u  pVn[        5       nUS:X  a  XF:X  a  U R                  R                  U5      nU R                  R                  US5      n	U	(       d"  [        R                  " [        S5      U-  5      eUR                  X	   R                  5       5        O[        5       n
U R                  R                  5        H%  u  pU" U5      (       d  M  U
R                  U	5        M'     U
 H$  n	UR                  X	   R                  5       5        M&     O:U R                  R                  5        Vs1 s H  oU   R                  5       iM     nnU[        1-  nX-  $ s  snf )zsThe named bookmark or all bookmarks.

Pattern matching is supported for `name`. See :hg:`help revisions.patterns`.
r   r   s"   bookmark takes one or no argumentss)   the argument to bookmark must be a string   literalNs   bookmark '%s' does not exist)getargsr   r   r   stringmatcherr   
_bookmarks
expandnamer  r   r0   r   r/   r   valuesr   )r&   r'   r(   r   bmr  r  r  bmsbmrev	matchrevsnamer1   s                r)   bookmarkr%  M  sd    1aACDEDG:;

 ",!9!9"!=we:}//44W=OO''6E++56@  GGDKOO%&I#4464==MM%(  7 #)* # '+oo&<&<&>?&>Aw{{}&>?G9C< @s   <F(s   branch(string or set)c                  ^ ^^^	^
^ T R                  5       R                  m	U	U 4S jm
 [        US5      m[        R                  " T5      u  p4mUS:X  at  T R                  5       R                  U5      (       a  UR                  U
U4S jST4S9$ TR                  S5      (       a"  [        R                  " [        S5      U-  5      eOUR                  U
U4S	 jST4S9$ [        T [        T 5      U5      n[        5       mU H  nTR!                  T
" U5      5        M     UR"                  mUR                  UUU
4S
 jU4S jS9$ ! [        R                   a     N|f = f)z
All changesets belonging to the given branch or the branches of the given
changesets.

Pattern matching is supported for `string`. See
:hg:`help revisions.patterns`.
c                v   >  T" U 5      S   $ ! [         R                   a    TU    R                  5       s $ f = frW   )r   r   branch)r1   getbir&   s    r)   	getbranchbranch.<locals>.getbranch~  s<    	$8A;$$ 	$7>>##	$s   
 '88r+   r  c                    > T" T" U 5      5      $ r5    r1   r*  r  s    r)   r   branch.<locals>.<lambda>  s    gil3r+      <branch %r>r	  s   literal:s   branch '%s' does not existc                    > T" T" U 5      5      $ r5   r-  r.  s    r)   r   r/    s    ')A,/r+   c                8   > T" U 5      =(       d    T" U 5      T;   $ r5   r-  )r1   rx   r   r*  s    r)   r   r/    s    !A$+)A,!++r+   c                     > S[        T 5      -  $ )Nr0  r:   )rx   s   r)   r   r/    s    (1+5r+   )revbranchcache
branchinfor   r   r  	branchmap	hasbranchr  
startswithr   r0   r   r#   r*   r@   r   r   __contains__)r&   r'   r(   r  r  r   r1   rx   r   r)  r*  r  s   `      @@@@@r)   r(  r(  s  sW    !,,E$a
 ",!9!9!!<w: ~~))'22}}3,a0 %   ||K((++34w>  )
 ==/>1:M !   	t[&*AA	il 	A==+5   7  s   E EEs   phasedivergent()c                f    [        USS[        S5      5        [        R                  " U S5      nX-  $ )zMutable changesets marked as successors of public changesets.

Only non-public and non-obsolete changesets can be `phasedivergent`.
(EXPERIMENTAL)
r   s!   phasedivergent takes no arguments   phasedivergentr  r   obsmodgetrevs)r&   r'   r(   phasedivergents       r)   r@  r@    s2     Aq!Q;<=^^D*;<N""r+   s   bundle()c                     U R                   R                  nX-  $ ! [         a     [        R                  " [        S5      5      ef = f)zEChangesets in the bundle.

Bundle must be specified by the -R option.s$   no bundle provided - specify with -R)rK   
bundlerevsAttributeErrorr   Abortr   )r&   r'   r(   rB  s       r)   bundlerE    sJ    F^^..
   Fkk!CDEEFs	    *Ac                   ^ ^^^^ [         R                  " T5      S:H  mS/mUUUUU 4S jnUR                  US[        R                  " T5      T4S9$ )zmHelper for status-related revsets (adds, removes, modifies).
The field parameter says which kind is desired.
r   Nc                  >^ T	U    nTS   (       a  T(       a3  [         R                  " T	R                  T	R                  5       T/US9TS'   TS   mS nTc   eTR	                  5       (       d0  [        TR                  5       5      S:X  a  TR                  5       S   nUb  X!R                  5       ;  a  gO)[        U4S jUR                  5        5       5      (       d  g[        T	R                  UR                  5       R                  5       UR                  5       5      T5      nUb  X#;   a  gg [        U4S jU 5       5      (       a  gg )Nr   ctxr   Fc              3  4   >#    U  H  nT" U5      v   M     g 7fr5   r-  .0r   rS   s     r)   	<genexpr>/checkstatus.<locals>.matches.<locals>.<genexpr>  s     /YqttY   Tc              3  4   >#    U  H  nT" U5      v   M     g 7fr5   r-  rK  s     r)   rM  rN    s     'A1Q44rO  )matchmodr   rootgetcwdanypatsra   filesanyr   r  r   node)
r(   r   fnamerU  rS   fieldhassetmcacher   r&   s
       @r)   matchescheckstatus.<locals>.matches  s	   GayF tyy$++-#ANF1I1I}}yy{{s1779~2GGIaLEGGI% & /QWWY///ADDFKKM1668<eD~  '''' (r+   s   <status.%s %r>r	  )rQ  patkindr  r   sysbytes)r&   r'   r   rY  r\  rZ  r[  s   ` `` @@r)   r   r     s[     c"f,FVF 0 ==,h.?.?.FL   r+   c                B   U(       d
  [        5       $ [        5       nU R                  R                  nUR	                  5       nU HN  nXe::  a  M
  U" U5      u  pxXr;   a  UR                  U5        U[        :w  d  M6  X;   d  M=  UR                  U5        MP     [        U5      $ r5   )rA   r   rK   r   r   r   r   )	r&   r'   	parentsetr   prminrevr1   r   p2s	            r)   	_childrenre    s}    y	B		"	"B]]_F;A?FF1I=R_FF1I  2;r+   s   children(set)c                N    [        U [        U 5      U5      n[        XU5      nX-  $ )z&Child changesets of changesets in set.)r*   r@   re  )r&   r'   r(   r   r   s        r)   r   r     s+     	t[&*A	4	#B;r+   s   closed()c                Z   ^  [        USS[        S5      5        UR                  U 4S jSS9$ )zChangeset is closed.r   s   closed takes no argumentsc                *   > TU    R                  5       $ r5   )closesbranchr1   r&   s    r)   r   closed.<locals>.<lambda>  s    $q'&&(r+   s   <branch closed>r	  )r  r   r  r   s   `  r)   closedrl    s5     Aq!Q345==(3E   r+   s   _commonancestorheads(set)c                    [        U [        U 5      U[        S9nU R                  R                  " [        U5      6 nU[        U5      -  $ )Nr   )r*   r@   ri   rK   _commonancestorsheadslistrA   )r&   r'   r(   	startrevsancss        r)   _commonancestorheadsrr  
  s@     t[.BI>>//iADGDM!!r+   s   commonancestors(set)c                    [        U [        U 5      U[        S9nU(       d
  [        5       $ U H'  nU[        R
                  " U [        U/5      5      -  nM)     U$ )z8Changesets that are ancestors of every changeset in set.r   )r*   r@   ri   rA   r	   r   )r&   r'   r(   rp  r1   s        r)   commonancestorsrt    sP     t[.BIy%$$T7A3<88 Mr+   s   conflictlocal()c                T   [        USS[        S5      5        SSKJn  UR                  R	                  U 5      nUR                  5       (       aR  U R                  R                  UR                  5      (       a(  XR                  R                  UR                  5      1-  $ [        5       $ )zThe local side of the merge, if currently in an unresolved merge.

"merge" here includes merge conflicts from e.g. 'hg rebase' or 'hg graft'.
r   s    conflictlocal takes no argumentsr   
mergestate)r  r    rw  readactiverK   hasnodelocalr/   rA   r&   r'   r(   mergestatemodrw  s        r)   conflictlocalr  "       Aq!Q:;<-))..t4Jt~~55j6F6FGG++J,<,<=>>>9r+   s   conflictother()c                T   [        USS[        S5      5        SSKJn  UR                  R	                  U 5      nUR                  5       (       aR  U R                  R                  UR                  5      (       a(  XR                  R                  UR                  5      1-  $ [        5       $ )zThe other side of the merge, if currently in an unresolved merge.

"merge" here includes merge conflicts from e.g. 'hg rebase' or 'hg graft'.
r   s    conflictother takes no argumentsr   rv  )r  r   rx  rw  ry  rz  rK   r{  otherr/   rA   r}  s        r)   conflictotherr  2  r  r+   s   contains(pattern)d   )r   c                b   ^ ^ [        U[        S5      5      mUU 4S jnUR                  UST4S9$ )a(  The revision's manifest contains a file matching pattern (but might not
modify it). See :hg:`help patterns` for information about file patterns.

The pattern without explicit kind like ``glob:`` is expected to be
relative to the current directory and match against a file exactly
for efficiency.
s   contains requires a patternc                j  > [         R                  " T5      (       d<  [        R                  " TR                  TR                  5       T5      nUTU    ;   a  g gTU    n[         R                  " TR                  TR                  5       T/US9nUR                  5        H  nU" U5      (       d  M    g   g)NTrH  F)rQ  r^  r   	canonpathrR  rS  r   manifest)r(   patsr   rS   r   r   r&   s        r)   r\  contains.<locals>.matchesN  s    $$%%diiDDtAw   QAtyy$++-#AFAZZ\Q44 " r+   s   <contains %r>r	  )r   r   r  )r&   r'   r(   r\  r   s   `   @r)   containsr  B  s7     Aq78
9C ==,<c+B=CCr+   s   converted([id])c                   ^ ^^ Sm[        USS[        S5      5      nU(       a  [        US   [        S5      5      mU U4S jmUR                  U4S jST4S	9$ )
zChangesets converted from the given identifier in the old repository if
present, or all converted changesets if no identifier is specified.
Nr   r   s#   converted takes one or no argumentss   converted requires a revisionc                   > TU    R                  5       R                  SS 5      nUS L=(       a    TS L =(       d    UR                  T5      $ )Ns   convert_revision)r.   r  r9  )r1   sourcer&   r/   s     r)   _matchvalueconverted.<locals>._matchvaluen  sD    a$$%8$?T!Msd{'Lf6G6G6LMr+   c                   > T" U 5      $ r5   r-  r1   r  s    r)   r   converted.<locals>.<lambda>s  	    +a.r+   s   <converted %r>r	  )r  r   r   r  )r&   r'   r(   lr  r/   s   `   @@r)   	convertedr  ^  sb     C1aABCA!a @ABN == ,=s+C   r+   s   date(interval)c                   ^ ^ [        U[        S5      5      n[        R                  " U5      mUR	                  UU 4S jSU4S9$ )z5Changesets within the interval, see :hg:`help dates`.s   date requires a stringc                <   > T" TU    R                  5       S   5      $ rW   date)r(   dmr&   s    r)   r   date.<locals>.<lambda>~  s    "T!W\\^A&'r+   s	   <date %r>r	  )r   r   r   	matchdater  )r&   r'   r(   dsr  s   `   @r)   r  r  w  sG     
1a12	3B			B	B=='<2D   r+   s   desc(string)c                x   ^ ^ [        U[        S5      5      n[        USS9u  pEmUR                  UU 4S jSU4S9$ )zSearch commit message for string. The match is case-insensitive.

Pattern matching is supported for `string`. See
:hg:`help revisions.patterns`.
s   desc requires a stringFr  c                6   > T" TU    R                  5       5      $ r5   description)r1   r  r&   s    r)   r   desc.<locals>.<lambda>  s    '$q'--/0r+   s	   <desc %r>r	  r  )r&   r'   r(   r  r  r  r  s   `     @r)   descr    sH     
1a12	3B.rGD7==0L";M   r+   c                    [        U [        U 5      U5      nU(       d
  [        5       $ [        R                  " XX4U5      nX-  $ r5   )r*   r@   rA   r	   r   )r&   r'   r(   r   r   r   rootsr   s           r)   _descendantsr    s>     4T*A.EyT+9MA:r+   s   descendants(set[, depth])c                ~   [        USS5      nSU;  a  [        R                  " [        S5      5      eS=pESU;   a-  [	        US   S5      nUS:  a  [        R                  " S	5      eUnS
U;   aB  [	        US
   [        S5      5      nUS:  a  [        R                  " [        S5      5      eUS-   n[        XUS   XES9$ )zChangesets which are descendants of changesets in set, including the
given changesets themselves.

If depth is specified, the result only includes changesets up to
the specified generation.
s   descendantsr   r   s%   descendants takes at least 1 argumentNr   s)   descendants expects an integer startdepthr   r   r   s$   descendants expects an integer depthr   r   r   )r   r   r#   r   r   r  r   s          r)   descendantsr    s     q.*ABDTq!IJKK!!J!M
 q5""#9::
4NAEF
 q5""1%6#788E	d6lz r+   s   _firstdescendantsc                    [        XUSS9$ r   )r  r   s      r)   _firstdescendantsr    s     aT::r+   s   destination([set])c                p  ^ Ub  [        U [        U 5      U5      nO[        U 5      n[        5       mU Hc  n[        X5      nSnUc  M  Uc
  [	        5       nUR                  U5        XS;   d  UT;   a  TR                  U5        MQ  Un[        X5      nUb  MN  Me     UR                  TR                  U4S jS9$ )zChangesets that were created by a graft, transplant or rebase operation,
with the given revisions specified as the source.  Omitting the optional set
is the same as passing all().
Nc                     > S[        T 5      -  $ )Ns   <destination %r>r4  )destss   r)   r   destination.<locals>.<lambda>  s    ,x>r+   r	  )	r*   r@   r   r3   ro  appendupdater  r:  )r&   r'   r(   sourcesr1   srclineager  s          @r)   destinationr    s     	}{40!4d#EE D$o&NN1 ~W%A(C# o	 . ==>   r+   s   diffcontains(pattern)n   c                  ^^^	 [        USS5      nSU;  a  [        R                  " [        S5      5      e[	        US   [        S5      5      n[
        R                  " U[        R                  5      n[        R                  " 5       mU4S jm[        R                  " U R                  XSS9m	UU	4S jnUR                  US	U4S
9$ )zSearch revision differences for when the pattern was added or removed.

The pattern may be a substring literal or a regular expression. See
:hg:`help revisions.patterns`.
s   diffcontainss   patterns&   diffcontains takes at least 1 arguments&   diffcontains requires a string patternc                   > T$ r5   r-  )rI  fmatchs    r)   makefilematcher%diffcontains.<locals>.makefilematcher  s    r+   T)diffc                   > SnTR                  [        U /5      T5       H/  u  p#pE[        [        R                  " XE5      S 5      (       d  M-  SnM1     U$ )NFT)searchfilesrA   r   grepmoddifflinestates)r/   foundr   rI  pstatesstatesr  searchers         r)   testdiffdiffcontains.<locals>.testdiff  sS    (0(<(<SENO)
$BW G**7;TBB	)

 r+   s   <diffcontains %r>r	  )r   r   r#   r   r   r   substringregexpreMrQ  alwaysr  grepsearcheruir  )
r&   r'   r(   r   r  regexpr  r  r  r  s
          @@@r)   diffcontainsr    s     q/:6Dq!JKLLZ!EFG ''6F __F ##DGGTEH ==-A7,K=LLr+   s   contentdivergent()c                f    [        USS[        S5      5        [        R                  " U S5      nX-  $ )z\
Final successors of changesets with an alternative set of final
successors. (EXPERIMENTAL)
r   s#   contentdivergent takes no arguments   contentdivergentr=  )r&   r'   r(   contentdivergents       r)   r  r     s3     Aq!Q=>?~~d,?@$$r+   s   expectsize(set[, size]))r   	takeorderc                   [        USS5      nSn[        U 5      S-   nSnSU;  d  SU;  a  [        R                  " [	        S5      5      e[        US   [	        S	5      [	        S
5      UU5      u  pVUS:  d  US:  a  [        R                  " [	        S5      5      e[        U [        U 5      US   US9nXV:w  a9  [        U5      U:  d  [        U5      U:  a  [	        S5      UU[        U5      4-  nO-XV:X  a(  [        U5      U:w  a  [	        S5      U[        U5      4-  nU(       a  [        R                  " U5      eU[        :X  a  X-  $ X-  $ )a  Return the given revset if size matches the revset size.
Abort if the revset doesn't expect given size.
size can either be an integer range or an integer.

For example, ``expectsize(0:1, 3:5)`` will abort as revset size is 2 and
2 is not between 3 and 5 inclusive.s
   expectsizes   set sizer   r   r+   s   sizer   s   invalid set of argumentss6   expectsize requires a size range or a positive integers"   size range bounds must be integerss   negative sizer   s8   revset size mismatch. expected between %d and %d, got %ds)   revset size mismatch. expected %d, got %d)
r   ra   r   r#   r   r   r*   r@   r0   rD   )	r&   r'   r(   r"   r   minsizemaxsizeerrr/   s	            r)   
expectsizer  ,  sZ    q-5DG$i!mG
CdfD0q!<=>>"W	
CD	
/0G {gkq!1233
{4($v,e
DCs3x'1SX5GKLHP
 

 
	CG 3<=HA
 
 ##C((||r+   s   extdata(source)c                    [        USS5      n[        UR                  S5      [        S5      5      n[        R
                  " X5      nU[        U5      -  $ )z:Changesets in the specified extdata source. (EXPERIMENTAL)s   extdatar-   s(   extdata takes at least 1 string argument)r   r   r  r   r   extdatasourcerA   )r&   r'   r(   r   r  datas         r)   extdatar  X  sR     q*i0D	
56F
   .DGDM!!r+   s	   extinct()c                f    [        USS[        S5      5        [        R                  " U S5      nX-  $ )zBObsolete changesets with obsolete descendants only. (EXPERIMENTAL)r   s   extinct takes no argumentss   extinctr=  )r&   r'   r(   extinctss       r)   extinctr  f  s1     Aq!Q456~~dJ/Hr+   s   extra(label, [value])c                T  ^ ^^^^ [        USS5      nSU;  a  [        R                  " [        S5      5      e[	        US   [        S5      5      mSmSU;   a2  [	        US   [        S5      5      m[
        R                  " T5      u  nmmUUU U4S	 jmUR                  U4S
 jSTT4S9$ )zChangesets with the given label in the extra metadata, with the given
optional value.

Pattern matching is supported for `value`. See
:hg:`help revisions.patterns`.
s   extras   label values   labels   extra takes at least 1 arguments(   first argument to extra must be a stringNs   values)   second argument to extra must be a stringc                n   > TU    R                  5       nTU;   =(       a    TS L =(       d    T" UT   5      $ r5   )r.   )r1   r.   r2   r  r&   values     r)   r  extra.<locals>._matchvalue  s3    Q~J5D=#IGE%L4IJr+   c                   > T" U 5      $ r5   r-  r  s    r)   r   extra.<locals>.<lambda>  r  r+   s   <extra[%r] %r>r	  )r   r   r#   r   r   r   r  r  )	r&   r'   r(   r   r  r  r2   r  r  s	   `    @@@@r)   r.   r.   o  s     q(N3Dtq!CDEEXEFE E4NAJK
  *77>eWK K == ,=ue+L   r+   s   filelog(pattern)c                  ^ [        U[        S5      5      n[        5       nU R                  n[        R
                  " U5      (       d4  [        R                  " U R                  U R                  5       U5      nU/nOB[        R                  " U R                  U R                  5       U/U S   S9mU4S jU S    5       nU GH  nU R                  U5      n0 n	Sn
[        U5       H  nUR                  U5      nX;   a  UR                  X   5        M.  UR                  U5      nX;   a  UR                  U5        MW  U
c  M\  [!        X5      S-   nSn
UR#                  U5       Hk  nXeR%                  U5      ;   d  M  XeR'                  U5      ;   d  M/   X   R)                  U5      nUU	;  a"  UU:X  a  UR                  U5        Un
  M  XU'   Mk  Mm     M     GM     X-  $ ! [*        R,                   a     M  f = f)a  Changesets connected to the specified filelog.

For performance reasons, visits only revisions mentioned in the file-level
filelog, rather than filtering through all changesets (much faster, but
doesn't include deletes or duplicate changes). For a slower, more accurate
result, use ``file()``.

The pattern without explicit kind like ``glob:`` is expected to be
relative to the current directory and match against a file exactly
for efficiency.
s   filelog requires a patternNrH  c              3  F   >#    U  H  nT" U5      (       d  M  Uv   M     g 7fr5   r-  rK  s     r)   rM  filelog.<locals>.<genexpr>  s     /Jq!A$Js   !	!r   r   )r   r   r   rK   rQ  r^  r   r  rR  rS  r   filero  rW  r   linkrevr   r   revision	readfilesfilenoder   ManifestLookupError)r&   r'   r(   r   r   r   r   rU  flknownscanposfrr   lrstartr1   rT   rS   s                    @r)   filelogr    s    Aq67
8CA	BC  tyy$++-=NN499dkkmcUT
K/DJ/YYq\r(BB{ei BBxb	$ B(1,AKKN*qLLO/C% $ 0 0 3A ~#$7$%EE!H./G$)/0!H  . ( 	 F :	  %88 %$%s   2GGG5	4G5	s   first(set, [n]))r   r  r   c                    [        XX#5      $ )zAn alias for limit().)limitr%   s       r)   rP   rP     s     q((r+   c           	     Z  ^ [        X#S5      nS nSU;   a  [        U [        U 5      US   5      nSU;   a  [        US   [	        S5      U-  5      nUc  S /n/ nU Hz  nX   =mn	Uc  U S   m[
        R                  " U R                  U R                  5       U/U	SS9n
UR                  U4S jTR                  5       R                  U
5       5       5        M|     [        R                  " Xt5      nX-  $ Uc  [        U S   R                  5       /5      n[        R                   " XU5      nX-  $ )	Ns   file startrev   startrev   files   %s expected a pattern   .s   path)rI  defaultc              3  J   >#    U  H  nTU   R                  5       v   M     g 7fr5   )introfilectx)rL  r   rI  s     r)   rM  _follow.<locals>.<genexpr>  s#     O8N1Q,,..8N    #)r   r*   r@   r   r   rQ  r   rR  rS  extendr  walkr	   filerevancestorsrA   r/   r   )r&   r'   r(   r$  r   r   r   fctxsr1   mctxrS   r   rI  s               @r)   _followr    s+   q 01DDddK-tK/@A$d7mQ'?%@4%GH<6DA C$y4j		4;;=1#4A LLO8K8KA8NOO  ""56 :	 <DJNN,-.Dt;7:r+   s   follow([file[, startrev]])c                    [        XUS5      $ )z
An alias for ``::.`` (ancestors of the working directory's first parent).
If file pattern is specified, the histories of files matching given
pattern in the revision given by startrev are followed, including copies.
r    r  r   s      r)   followr    s     4I..r+      _followfirstc                    [        XUSSS9$ )Nr	  Tr   r  r   s      r)   _followfirstr    s    
 4OFFr+   s?   followlines(file, fromline:toline[, startrev=., descend=False])c           	     <   [        USS5      n[        US   5      S:w  a  [        R                  " [	        S5      5      eSnSU;   aW  [        U [        U 5      US   5      n[        U5      S:w  a  [        R                  " [	        S5      5      eUR                  5       n[        US	   [	        S
5      5      n[	        S5      n[        R                  " XXg5      n[        R                  " [        US   S   [	        S5      [	        S5      5      6 u  pX   R                  U5      nSnSU;   a  [        US   [	        S5      5      nU(       a*  [!        S ["        R$                  " XU
5       5       SS9nX-  $ [!        S ["        R&                  " XU
5       5       SS9nX-  $ )a  Changesets modifying `file` in line range ('fromline', 'toline').

Line range corresponds to 'file' content at 'startrev' and should hence be
consistent with file size. If startrev is not specified, working directory's
parent is used.

By default, ancestors of 'startrev' are returned. If 'descend' is True,
descendants of 'startrev' are returned though renames are (currently) not
followed in this direction.
s   followliness   file *lines startrev descends   linesr   s!   followlines requires a line ranger  r  s(   followlines expects exactly one revisionr  s   followlines requires a patterns$   followlines expects exactly one filer   s,   followlines expects a line number or a ranges"   line range bounds must be integersFs   descends"   descend argument must be a booleanc              3  F   #    U  H  u  pUR                  5       v   M     g 7fr5   r/   rL  r   
_lineranges      r)   rM  followlines.<locals>.<genexpr>8  %      &MA &   !T)iterascc              3  F   #    U  H  u  pUR                  5       v   M     g 7fr5   r  r  s      r)   rM  r  B  r  r  )r   ra   r   r#   r   r*   r@   rQ   r   r   parsefollowlinespatternr   processlineranger   filectx
getbooleangeneratorsetr	   blockdescendantsblockancestors)r&   r'   r(   r   r/   r   r   msgrX  fromlinetolinefctxdescendrss                 r)   followlinesr#    s    q.*IJD
4>aq!EFGG
CddK-tK/@At9>""=>  iik
DM1%F#G
HC
3
4C++Ds@E,,	N1=>34	

H 9U#DGT34

 %*%;%;F& 
& ; %*%9%9F& 
 ;r+   s   nodefromfile(path)c                   [        U[        S5      5      n[        5       n [        R                  " US5       nU H4  nUR                  5       n[        X5      nUc  M#  UR                  U5        M6     SSS5        U[        U5      -  $ ! , (       d  f       N= f! [         aJ  n	[        S5      n
X[        R                  " U	R                  5      4-  n
[        R                  " U
5      eSn	A	ff = f)zRead a list of nodes from the file at `path`.

This applies `id(LINE)` to each line of the file.

This is useful when the amount of nodes you need to specify gets too large
for the command line.
s    nodefromfile require a file pathrbNs   cannot open nodes file "%s": %s)r   r   r   r   openstrip_noder   OSErrorr   
strtolocalstrerrorr   rD  rA   )r&   r'   r(   path
listed_revr   linerT   rnexcrS   s              r)   nodefromfiler1  M  s     Q=>?DJ
]]4&!JJL4^>NN2&	  ' GJ''' '&  01	H''566kk!ns;   B "B	B	3B 	
BB B 
C.$AC))C.s   all()c                L    [        USS[        S5      5        U[        U 5      -  $ )z&All changesets, the same as ``0:tip``.r   s   all takes no arguments)r  r   r`   r   s      r)   getallr3  f  s'     Aq!Q012GDM!!r+   s   grep(regex)c                D  ^ ^  [         R                  " [        U[        S5      5      5      mUU 4S jnUR                  USTR                  4S9$ ! [         R                   a;  n[        R
                  " [        S5      [        R                  " U5      -  5      eSnAff = f)zLike ``keyword(string)`` but accepts a regex. Use ``grep(r'...')``
to ensure special escape characters are handled correctly. Unlike
``keyword(string)``, the match is case-sensitive.
s   grep requires a strings   invalid match pattern: %sNc                   > TU    nUR                  5       UR                  5       UR                  5       /-    H  nTR                  U5      (       d  M    g   gNTF)rU  r  r  search)r(   r   egrr&   s      r)   r\  grep.<locals>.matches|  sG    Gaffh88Ayy|| 9 r+   s	   <grep %r>r	  )
r  compiler   r   r   r#   r   forcebytestrr  r  )r&   r'   r(   r8  r\  r9  s   `    @r)   r   r   n  s    
ZZ	!Q'@%ABC ==L"**+E=FF 88 
*+j.E.Ea.HH
 	

s   )A B$6BBs   _matchfilesc           	       ^ ^	^
^^^^^^ [        USSS5      n/ / / smmm
Su  mm	U H  n[        US5      nUS S USS  pvUS:X  a  TR                  U5        M1  US:X  a  TR                  U5        MJ  US	:X  a  T
R                  U5        Mc  US
:X  a+  Tb  [        R                  " S5      eUS:X  a  [
        mM  UmM  US:X  a  T	b  [        R                  " S5      eUm	M  [        R                  " SU-  5      e   T	(       d  Sm	[        S TT-   T
-    5       5      mS /mT R                  R                  mU	U
UUUUUU U4	S jnUR                  USTTT
T	T4S9$ )Nr   s*   _matchfiles requires at least one argumentr   s%   _matchfiles requires string argumentsrt      p:s   i:s   x:s   r:s)   _matchfiles expected at most one revisionr+   s   d:s-   _matchfiles expected at most one default modes   invalid _matchfiles prefix: %ss   globc              3  T   #    U  H  n[         R                  " U5      S :H  v   M      g7f)r   N)rQ  r^  rL  rv   s     r)   rM  _matchfiles.<locals>.<genexpr>  s"     I8H1!!!$.8Hs   &(c           
     2  >	 U [         :X  a  TU    R                  5       nOT" U 5      nT
S   (       a
  T(       aB  Tc?  Tc  U OTn[        R                  " TR                  TR                  5       TT	TTU   TS9T
S'   T
S   nU H  nU" U5      (       d  M    g   g)Nr   )includeexcluderI  r  TF)r   rU  rQ  r   rR  rS  )r(   rU  r1   rS   r   r  r0  getfilesrZ  incr[  r  r&   r/   s        r)   r\  _matchfiles.<locals>.matches  s    <GMMOEQKEayV[cA 		GF1I 1IAtt  r+   sC   <matchfiles patterns=%r, include=%r exclude=%r, default=%r, rev=%r>r	  )
r  r   r  r   r#   r   rV  rK   r  r  )r&   r'   r(   r  argr   prefixr  r\  r  r0  rF  rZ  rG  r[  r  r/   s   `        @@@@@@@@r)   _matchfilesrK    s    	1bGHARND#sLCcCD"1quU?KKu_JJuu_JJuu_&&@  |u_"&&D  G""#Dv#MNN3 4 Is
S8HIIFVF ~~''H 0 ==/
   r+   s   file(pattern)c                N    [        U[        S5      5      n[        XSSU-   45      $ )zChangesets affecting files matched by pattern.

For a faster but less accurate result, consider using ``filelog()``
instead.

This predicate uses ``glob:`` as the default kind of pattern.
s   file requires a pattern   stringr?  )r   r   rK  r   s       r)   hasfilerN    s,     Aq34
5Cti%=>>r+   s   head()c                   ^ [        USS[        S5      5        [        5       nU R                  mU R	                  5       R                  5        H  nUR                  U4S jU 5       5        M      U[        U5      -  $ )z!Changeset is a named branch head.r   s   head takes no argumentsc              3  F   >#    U  H  nTR                  U5      v   M     g 7fr5   r  )rL  hr   s     r)   rM  head.<locals>.<genexpr>  s     (R"&&))Rs   !)r  r   r   rK   r7  	iterheadsr  rA   )r&   r'   r(   hslsr   s        @r)   headrV    sd     Aq!Q123	B	Bnn((*
		(R(( +GBKr+   s
   heads(set)c                   U[         :X  a  [        n[        U [        U 5      X#S9nSn[        U;   aP  U S   R                  5        Vs/ s H  ofR                  5       PM     nn[        U5      nUR                  [        5        U R                  R                  U5      nUb&  UR                  U5        UR                  [        5        [        U5      nX-  $ s  snf )z'Members of set with no children in set.r   N)rb   rD   r*   r@   r   parentsr/   r   discardrK   headrevsdifference_updater   rA   )r&   r'   r(   r"   inputsetwdirparentsrv   r   s           r)   r   r     s     dK-q>HK((,T
(:(:(<=(<1uuw(<=x=!NN##H-E,		'ENE> >s   Cs   hidden()c                f    [        USS[        S5      5        [        R                  " U S5      nX-  $ )zHidden changesets.r   s   hidden takes no argumentss   visible)r  r   r   
filterrevs)r&   r'   r(   
hiddenrevss       r)   hiddenra    s3     Aq!Q345$$T:6Jr+   s   keyword(string)c                   ^ ^ [         R                  " [        U[        S5      5      5      mUU 4S jnUR	                  UST4S9$ )zSearch commit message, user name, and names of changed files for
string. The match is case-insensitive.

For a regular expression or case sensitive search of these fields, use
``grep(regex)``.
s   keyword requires a stringc                   > TU    n[        U4S jUR                  5       UR                  5       UR                  5       /-    5       5      $ )Nc              3  V   >#    U  H  nT[         R                  " U5      ;   v   M      g 7fr5   r   r  )rL  tkws     r)   rM  +keyword.<locals>.matches.<locals>.<genexpr>&  s&      
< (..##<s   &))rV  rU  r  r  )r1   r   rg  r&   s     r)   r\  keyword.<locals>.matches$  sB    G 
WWY!&&(AMMO!<<
 
 	
r+   s   <keyword %r>r	  )r   r  r   r   r  )r&   r'   r(   r\  rg  s   `   @r)   keywordrj    s?     
	!Q'C%DE	FB
 ==OR+@=AAr+   s   limit(set[, n[, offset]])c                   [        USS5      nSU;  a  [        R                  " [        S5      5      e[	        UR                  S5      [        S5      SS9nUS	:  a  [        R                  " [        S
5      5      e[	        UR                  S5      [        S5      S	S9nUS	:  a  [        R                  " [        S5      5      e[        U [        U 5      US   5      nUR                  XfU-   5      nU[        :X  a
  US:  a  X-  $ X-  $ )z>First n members of set, defaulting to 1, starting from offset.r   s   set n offsetr   s%   limit requires one to three arguments   ns   limit expects a numberr   )r  r      negative number to selects   offsets   negative offset)
r   r   r#   r   r   r  r*   r@   slicerD   )	r&   r'   r(   r"   r   limofsosrU  s	            r)   r  r  .  s     q(O4DTq!IJKK
TXXd^Q'@%A1
MC
Qwq!=>??
Q891C Qwq!3455	k$'f	6B	#Sy	!Ba{;r+   s   last(set, [n])c                   [        USS[        S5      5      nSn[        U5      S:X  a  [        US   [        S5      5      nUS:  a  [        R
                  " [        S5      5      e[        U [        U 5      US   5      nUR                  5         UR                  SU5      nU[        :X  a
  US:  a  X-  $ UR                  5         Xq-  $ )z'Last n members of set, defaulting to 1.r   rt   s"   last requires one or two argumentss   last expects a numberr   rm  )r  r   ra   r   r   r#   r*   r@   reversern  rD   )r&   r'   r(   r"   r  ro  rq  rU  s           r)   rQ   rQ   F  s     	1a@ABA
C
1v{1q!9:;
Qwq!=>??	k$'1	.BJJL	!S	Ba{JJL;r+   s   max(set)c                    [        U [        U 5      U5      n UR                  5       nXA;   a  [        U/SX4S9$  [        SX4S9$ ! [         a     Nf = f)z.Changeset with highest revision number in set.s   <max %r, %r>datarepr)r*   r@   r   rA   
ValueErrorr&   r'   r(   rq  rS   s        r)   maxrevry  Z  m     
k$'	+BFFH;A3/6)FGG  _f9::	   	   !A 
AAs   merge()c                z   ^ ^ [        USS[        S5      5        T R                  mUU 4S jnUR                  USS9$ )zChangeset is a merge changeset.r   s   merge takes no argumentsc                   >  TR                  U 5      S   [        :g  $ ! [        R                   a    [	        TU    R                  5       5      s $ f = fr_   )r   r   r   r   boolrd  )r1   r   r&   s    r)   ismergemerge.<locals>.ismergep  sK    	&==#A&'11$$ 	&Q

%%	&s    0AAs   <merge>r	  )r  r   rK   r  )r&   r'   r(   r  r   s   `   @r)   merger  i  s<     Aq!Q234	B& ==:=66r+   s   branchpoint()c                d  ^^ [        USS[        S5      5        U R                  nU(       d
  [        5       $ [	        U5      mS/[        U 5      T-
  -  mUR                  TS-   S9 H3  nUR                  U5       H  nUT:  d  M  TUT-
  ==   S-  ss'   M     M5     UR                  UU4S jSS9$ )z$Changesets with more than one child.r   s   branchpoint takes no argumentsr   )r  c                   > TU T-
     S:  $ r_   r-  )r1   baserevparentscounts    r)   r   branchpoint.<locals>.<lambda>  s    ,q7{+a/r+   s   <branchpoint>r	  )	r  r   rK   rA   r   ra   r   r   r  )r&   r'   r(   r   r1   rv   r  r  s         @@r)   branchpointr  y  s     Aq!Q89:	By &kG3#d)g-.LWW7Q;W'q!AG|Q[)Q.) " ( ==/:J   r+   s   min(set)c                    [        U [        U 5      U5      n UR                  5       nXA;   a  [        U/SX4S9$  [        SX4S9$ ! [         a     Nf = f)z-Changeset with lowest revision number in set.s   <min %r, %r>ru  )r*   r@   r   rA   rw  rx  s        r)   rc  rc    rz  r{  s   modifies(pattern)c                F    [        U[        S5      5      n[        XUS5      $ )zChangesets modifying files matched by pattern.

The pattern without explicit kind like ``glob:`` is expected to be
relative to the current directory and match against a file or a
directory.
s   modifies requires a patternmodifiedr   r   s       r)   modifiesr    s%     Aq78
9CtS*55r+   s   named(namespace)c           	       ^  [        USS[        S5      5      n[        US   [        S5      5      n[        R                  " U5      u  pVn[        5       nUS:X  aQ  UT R                  ;  a"  [        R                  " [        S5      U-  5      eUR                  T R                  U   5        OCT R                  R                  5        H%  u  pU" U	5      (       d  M  UR                  U5        M'     [        5       n
U HW  nUR                  T 5       H?  n	XR                  ;  d  M  U
R                  U 4S jUR                  T U	5       5       5        MA     MY     U
[        1-  n
X-  $ )zxThe changesets in a given namespace.

Pattern matching is supported for `namespace`. See
:hg:`help revisions.patterns`.
r   s#   named requires a namespace argumentr   s&   the argument to named must be a stringr  s   namespace '%s' does not existc              3  J   >#    U  H  nTU   R                  5       v   M     g 7fr5   r  )rL  rT   r&   s     r)   rM  named.<locals>.<genexpr>  s     I4HqT!W[[]]4Hr  )r  r   r   r   r  r   namesr   r0   r   r   	listnames
deprecatedr  rH   r   )r&   r'   r(   r   nsr  r  r  
namespacesr$  r  s   `          r)   namedr    s0    1aADEFD	Q	
34
B
 (55b9D7Jz$**$''23b8  	tzz'*+

((*HDt}}r" + EELL&D==(IBHHT44HII ' 
 
gYE>r+   c                   Sn[        U5      SU R                  R                  -  :X  a'   U R                  R	                  [        U5      5      nU$  [        R                  " X5      nUb  U R                  R	                  U5      nU$ ! [        R                   a
    [        n U$ [        R                  [        4 a    Sn U$ f = f! [         a     U$ [        R                   a
    [        n U$ f = f)zprocess a node inputNrt   )ra   nodeconstantsnodelenrK   r/   r   r   r   r   binasciiErrorLookupErrorr   resolvehexnodeidprefix)r&   rT   r/  pms       r)   r(  r(    s    	B
1vT''////	##CF+B I	//8B~^^''+
 I $$ 	B I , 	B I	  	 I $$ 	BI	s/   $B 4C C$CC
C0C0/C0s
   id(string)c                    [        USS[        S5      5      n[        US   [        S5      5      n[        X5      nUc
  [	        5       $ [	        U/5      nXa-  $ )zBRevision non-ambiguously specified by the given hex string prefix.r   s   id requires one argumentr   s   id requires a string)r  r   r   r(  rA   )r&   r'   r(   r  rT   r/  results          r)   node_r    sY     	1a678A!A$123A	tB	zybT]F?r+   s   none()c                D    [        USS[        S5      5        [        5       $ )zNo changesets.r   s   none takes no arguments)r  r   rA   r   s      r)   noner    s      Aq!Q1239r+   s
   obsolete()c                f    [        USS[        S5      5        [        R                  " U S5      nX-  $ )z6Mutable changeset with a newer version. (EXPERIMENTAL)r   s   obsolete takes no argumentss   obsoleter=  )r&   r'   r(   	obsoletess       r)   r   r     s1     Aq!Q567t[1Ir+   s   only(set, [set])c                   U R                   n[        USS[        S5      5      n[        U [	        U 5      US   5      n[        U5      S:X  a`  U(       d
  [        5       $ [        [        R                  " XS5      5      nUR                  5        Vs/ s H  nXv;  d  M
  Xu;  d  M  UPM     nnO[        U [	        U 5      US   5      n[        UR                  XS95      n	X-  $ s  snf )zChangesets that are ancestors of the first set that are not ancestors
of any other head in the repo. If a second set is specified, the result
is ancestors of the first set that are not ancestors of the second set
(i.e. ::<set1> - ::<set2>).
r   rt   s   only takes one or two argumentsr   F)commonr   )rK   r  r   r*   r@   ra   rA   r   r	   r   rZ  findmissingrevs)
r&   r'   r(   r   r   rD  r  r/   rE  resultss
             r)   onlyr    s     
B1aA@ABDT;t,d1g6G
4yA~9%..teDE {{}
$% .1n $ 	 
 {40$q':"$$G$CDG 
s   	C!C!#C!s   origin([set])c                   ^  Ub  [        T [        T 5      U5      nO[        T 5      nU 4S jnU Vs1 s H
  oT" U5      iM     nnUS1-  nX-  $ s  snf )aV  
Changesets that were specified as a source for the grafts, transplants or
rebases that created the given revisions.  Omitting the optional set is the
same as passing all().  If a changeset created by these operations is itself
specified as a source for one of these operations, only the source changeset
for the first operation is selected.
Nc                P   > [        TU 5      nUc  g  [        TU5      nUc  U$ UnM  r5   )r3   )r/   r  prevr&   s      r)   	_firstsrcorigin.<locals>._firstsrc2  s:    D#&; s+D|
C r+   )r*   r@   )r&   r'   r(   r  r  r1   os   `      r)   originr  $  s`     	}t[.2D!
  %%u!1uA%$KA :	 	&s   As   outgoing([path])c                N   SSK JnJn  [        USS[	        S5      5      nU=(       a    [        US   [	        S5      5      =(       d    SnU(       a  U/nO/ n[        5       n[        R                  " X R                  U5       H  n	U	R                  / 4n
UR                  X U
/ 5      u  pU(       a   U Vs/ s H  oR                  U5      PM     nnUR                  U 0 U	5      n U R                  R                  5          UR                  XUS9nSSS5        UR!                  5         UR#                  WR$                  5        M     U R&                  nU Vs1 s H  nUR)                  U5      iM     nnUU-  $ s  snf ! , (       d  f       Nt= f! UR!                  5         f = fs  snf )	zChangesets not found in the specified destination repository, or the
default push location.

If the location resolve to multiple repositories, the union of all
outgoing changeset will be used.
r   )	discoveryhgr   s"   outgoing takes one or no argumentss#   outgoing requires a repository pathr+   )	onlyheadsN)rx  r  r  r  r   r   r   r   get_push_pathsr  r(  addbranchrevslookuppeersilentfindcommonoutgoingcloser  missingrK   r/   )r&   r'   r(   r  r  r  destr  r  r,  branchesr   checkoutr/   r  outgoingr   r1   r  s                      r)   r  r  E  sh    	1a@ABA 	
Hi!a FGHOC 	 eG&&tWWe<;;?))$hC045KK$D5b$'	!$774 8  "
 KKMx''( = 
B#$GqGA$A: 6 "!
 KKM 	%s0   3E7#F=E<FF"<
F
	FFs	   p1([set])c                   Uc?  X   R                  5       R                  5       nUS:  a  U[        U/5      -  $ [        5       $ [        5       nU R                  n[        U [        U 5      U5       H'  n UR                  UR                  U5      S   5        M)     U[        1-  nX-  $ ! [        R                   a3    UR                  X   R                  5       R                  5       5         M  f = f)z<First parent of changesets in set, or the working directory.r   )r   r/   rA   r   rK   r*   r@   r   r   r   r   r   )r&   r'   r(   rv   r   r   r1   s          r)   r   r   r  s     	yGJJL6GQCL((y	B	BD+d+Q/	'FF2==#A&' 0
 7)OB ; $$ 	'FF47::<##%&	's   3#B((AC/.C/s	   p2([set])c                6   UcE  X   R                  5       n US   R                  5       nUS:  a  U[        U/5      -  $ [        5       $ [	        5       nU R
                  n[        U [        U 5      U5       H'  n UR                  UR                  U5      S   5        M)     U[        1-  nX-  $ ! [         a    [        5       s $ f = f! [        R                   a<    X   R                  5       n[        U5      S:X  a  UR                  US   5         M   M  f = f)z=Second parent of changesets in set, or the working directory.r   r   rt   )rX  r/   rA   
IndexErrorr   rK   r*   r@   r   r   r   r   ra   r   )r&   r'   r(   r   rv   r   r1   rX  s           r)   rd  rd    s	    	yW__	1		AAv,,9 
B	BD+d+Q/	#FF2==#A&' 0 7)OB ;  	9	 $$ 	#goo'G7|q wqz" !	#s)   'B. 	B. 9#C.CCA	DDc                    [        XU5      $ r5   )r   r%   s       r)   
parentpostr    s    dAr+   s   parents([set])c                   Uc0  X   R                  5        Vs1 s H  o3R                  5       iM     nnOZ[        5       nU R                  nUR                  nUR
                  n[        U [        U 5      U5       H  n U" U" U5      5        M     U[        1-  nX-  $ s  snf ! [        R                   a#    U" S X   R                  5        5       5         M_  f = f)zM
The set of all parents for all changesets in set, or the working directory.
c              3  @   #    U  H  oR                  5       v   M     g 7fr5   r  rA  s     r)   rM  parents.<locals>.<genexpr>  s     6$5q5577$5s   )rX  r/   r   rK   r  r   r*   r@   r   r   r   )	r&   r'   r(   rv   r   r   upr   r1   s	            r)   rX  rX    s    
 	y#w010!eeg01U^^YY]]
k$/3A7:a=! 4
 7)OB; 2 (( 76DGOO$5667s   B<B!!3CCc                :    U R                   R                  XU5      $ )z,helper to select all rev in <targets> phases)_phasecache	getrevset)r&   r'   targetss      r)   _phaser    s    %%dV<<r+   s   _internal()c                d    [        USS[        S5      5        [        X/[        R                  Q76 $ )Nr   s   _internal takes no arguments)r  r   r  r   all_internal_phasesr   s      r)   	_internalr    s,    Aq!Q678$<!;!;<<r+   s   _phase(idx)c                T    [        USSS5      n[        US   S5      n[        XU5      $ )Nr   s   _phase requires one argumentr   s   _phase expects a number)r  r   r  )r&   r'   r(   r  targets        r)   phaser    s1    1a89A!89F$''r+   s   draft()c                h    [        USS[        S5      5        [        R                  n[	        XU5      $ )zChangeset in draft phase.r   s   draft takes no arguments)r  r   r   draftr  r&   r'   r(   r  s       r)   r  r    s.     Aq!Q234\\F$''r+   s   secret()c                h    [        USS[        S5      5        [        R                  n[	        XU5      $ )zChangeset in secret phase.r   s   secret takes no arguments)r  r   r   secretr  r  s       r)   r  r    s.     Aq!Q345]]F$''r+   s   stack([revs])c                    Uc  [         R                  " U 5      nX-  $ [        R                  " / 5      n[	        U [        U 5      U5       H  n[         R                  " X5      nX5-   nM     X-  $ )z\Experimental revset for the stack of changesets or working directory
parent. (EXPERIMENTAL)
)stackmodgetstackr   rA   r*   r@   )r&   r'   r(   stacksr  currentstacks         r)   r   r     so    
 	y""4( ? !!"%t[%6:H#,,T<L*F ; ?r+   c                \    [        US   5      nUS;  a  [        e [        5       nU R                  n[        U [        U 5      U5       H}  nUS:X  a  UR                  U5        M  US:X  a&   UR                  UR                  U5      S   5        MH   UR                  U5      nUS   [        :w  a  UR                  US   5        M}  M     X-  $ ! [        [        4 a     [        R                  " [        S5      5      ef = f! [        R                   a3    UR                  X   R                  5       R                  5       5         M  f = f! [        R                   aL    X   R!                  5       n[#        U5      S:X  a&  UR                  US   R                  5       5         GM]   GMa  f = f)zv``set^0``
The set.
``set^1`` (or ``set^``), ``set^2``
First or second parent, respectively, of all changesets in set.
r   )r   r   rt   s   ^ expects a number 0, 1, or 2r   rt   )intrw  	TypeErrorr   r#   r   r   rK   r*   r@   r   r   r   r   r/   r   rX  ra   )	r&   r'   r(   rT   r"   r   r   r1   rX  s	            r)   
parentspecr    sy   D!II  
B	BD+d+Q/6FF1I!V+r}}Q'*+---*1:(FF71:& ) 0" ;+ z" Dq!ABCCD (( +twzz|'')*+ (( -'//+w<1$FF71:>>+,, %-s1   C ,#D2E0C>AEEAF+*F+s   present(set)c                d     [        XX#5      $ ! [        R                   a    [        5       s $ f = f)zAn empty set, if any revision in set isn't found; otherwise,
all revisions in set.

If any of specified revisions is not present in the local repository,
the query is normally aborted. But this predicate allows the query
to continue even in such cases.
)r*   r   r0   rA   r%   s       r)   presentr    s1    dA--   y    //
   _notpublicc                R    [        USSS5        [        X/[        R                  Q76 $ )Nr   s   _notpublic takes no arguments)r  r  r   not_public_phasesr   s      r)   
_notpublicr  #  s'    Aq!56$:!9!9::r+   s"   _phaseandancestors(phasename, set)c                  ^ ^
^^ [        USSS5      n[        US   5      n[        T [        T 5      US   5      n[        R
                  m
[        R                  nT
T
US.nXG;  a  [        R                  " SU-  5      eXt   mT R                  R                  mUUU 4S jn[        R                  " T XXS9n	US	:X  a  U	R                  U
UU 4S
 j5      n	X-  $ )Nrt   s)   _phaseandancestors requires two argumentsr   r   )r     drafts   secrets   %r is not a valid phasenamec                   > T" TU 5      T:  $ r5   r-  )r/   getphaseminimalphaser&   s    r)   cutfunc#_phaseandancestors.<locals>.cutfunc?  s    c"\11r+   )r  r  c                   > T" TU 5      T:H  $ r5   r-  )r1   r  r  r&   s    r)   r   $_phaseandancestors.<locals>.<lambda>E  s    XdA%6%%?r+   )r  r   r*   r@   r   r  r  r   r#   r  r  r	   r   r  )r&   r'   r(   r   	phasenamer   r  phasenamemapr  r   r  r  r  s   `         @@@r)   _phaseandancestorsr  *  s     1aHID$q'"It[&Q0ALLE]]FL
 $=	IJJ*L%%H2 dA7DH{{?@=r+   s   public()c                d    [        USS[        S5      5        [        X[        R                  5      $ )zChangeset in public phase.r   s   public takes no arguments)r  r   r  r   publicr   s      r)   r  r  I  s)     Aq!Q345$..r+   s   remote([id [,path]])c                   SSK Jn  [        USS[        S5      5      nSn[	        U5      S:  a  [        US   [        S5      5      nUS:X  a  U S   R                  5       nSn[	        U5      S:  a  [        US   [        S	5      5      nU(       d  S
n[        R                  " SU R                  U5      nUR                  U 0 U5      nUR                  U5      n	X;   a#  X	   R                  5       n
X;   a  [        U
/5      $ [        5       $ )zLocal revision that corresponds to the given identifier in a
remote repository, if present. Here, the '.' identifier is a
synonym for the current local branch.
r   )r  r   rt   s(   remote takes zero, one, or two argumentsr  s   remote requires a string idr+   s!   remote requires a repository paths   defaults   remote)rx  r  r  r   ra   r   r(  r   get_unique_pull_path_objr  r  r  r/   rA   )r&   r'   r(   r  r  qr  r,  r  rT   r1   s              r)   remoter  Q  s      	1aFGHAA
1vzadA<=>DyJD
1vz1q!EFG++ItwwEDGGD"d#EQAyGKKM;A3<9r+   s   removes(pattern)c                F    [        U[        S5      5      n[        XUS5      $ )zChangesets which remove files matching pattern.

The pattern without explicit kind like ``glob:`` is expected to be
relative to the current directory and match against a file or a
directory.
s   removes requires a patternremovedr   r   s       r)   removesr  u  s%     Aq67
8CtS)44r+   s   rev(number)c                d     [        XU5      $ ! [        R                   a    [        5       s $ f = f)z+Revision with the given numeric identifier.)_revr   r0   rA   r   s      r)   r/   r/     s1    D!$$   yr  s   _rev(number)c                   [        USS[        S5      5      n [        [        US   [        S5      5      5      nU[        ;  a   U R                  R                  U5        U[        U/5      -  $ ! [        [
        4 a     [        R                  " [        S5      5      ef = f! [         a#    [        R                  " [        S5      U-  5      ef = f)Nr   s   rev requires one argumentr   s   rev requires a numbers   rev expects a numbers   unknown revision '%d')r  r   r  r   r  rw  r   r#   r>   rK   rW  r  r0   rA   )r&   r'   r(   r  s       r)   r  r    s     	1a789A;	!A$": ;<= 		INN" GQCL   z" ;q!89::;  	I''*B(Ca(GHH	Is   !A/ B" /0B"-Cs   revset(set)c                    [        XX#5      $ )zStrictly interpret the content as a revset.

The content of this special predicate will be strictly interpreted as a
revset. For example, ``revset(id(0))`` will be interpreted as "id(0)"
without possible ambiguity with a "id(0)" bookmark or tag.
)r*   r%   s       r)   revsetpredicater    s     $))r+   s   matching(revision [, field])c                J  ^ ^^^^ [        USS[        S5      5      n[        T [        T 5      US   5      mS/n[	        U5      S:  a&  [        US   [        S5      5      R                  5       n/ nU H:  nUS:X  a	  U/ SQ-  nM  US:X  a	  US	S/-  nM!  US
:X  a  SnUR                  U5        M<     [        U5      nSU;   a  SU;   a  UR                  S5        / SQmU4S jn[        U5      nUR                  US9  / mU 4S jU 4S jU 4S jU 4S jU 4S jU 4S jU 4S jU 4S jU 4S jU 4S jS.
nU HK  n	UR                  U	S5      n
U
c"  [        R                  " [        S5      U	-  5      eTR                  U
5        MM     U4S jmUUU4S jnUR                  US UT4S!9$ )"a  Changesets in which a given set of fields match the set of fields in the
selected revision or set.

To match more than one field pass the list of fields to match separated
by spaces (e.g. ``author description``).

Valid fields are most regular revision fields and some special fields.

Regular revision fields are ``description``, ``author``, ``branch``,
``date``, ``files``, ``phase``, ``parents``, ``substate``, ``user``
and ``diff``.
Note that ``author`` and ``user`` are synonyms. ``diff`` refers to the
contents of the revision. Two revisions matching their ``diff`` will
also match their ``files``.

Special fields are ``summary`` and ``metadata``:
``summary`` matches the first line of the description.
``metadata`` is equivalent to matching ``description user date``
(i.e. it matches the main metadata fields).

``metadata`` is the default field which is used when no fields are
specified. You can match more than one field at a time.
r   rt   s   matching takes 1 or 2 argumentsr   s   metadatas1   matching requires a string as its second argument)   user   description   date   diff   files   authorr     summaryr  )
   phase   parentsr  r     branchr
  r  r     substater  c                ^   >  TR                  U 5      $ ! [         a    [        T5      s $ f = fr5   )rL   rw  ra   )r   
fieldorders    r)   fieldkeyfuncmatching.<locals>.fieldkeyfunc  s2    	###A&& 	#z?"	#s    ,,)keyc                *   > TU    R                  5       $ r5   r  rj  s    r)   r   matching.<locals>.<lambda>	      47<<>r+   c                *   > TU    R                  5       $ r5   r(  rj  s    r)   r   r  	  s    T!W^^-r+   c                *   > TU    R                  5       $ r5   r  rj  s    r)   r   r  	  r  r+   c                *   > TU    R                  5       $ r5   r  rj  s    r)   r   r  	  s    $q'"5"5"7r+   c                *   > TU    R                  5       $ r5   )rU  rj  s    r)   r   r  	      DGMMOr+   c                *   > TU    R                  5       $ r5   )rX  rj  s    r)   r   r  	  s    d1goo/r+   c                *   > TU    R                  5       $ r5   )r  rj  s    r)   r   r  	  r  r+   c                "   > TU    R                   $ r5   )substaterj  s    r)   r   r  		  s    tAw//r+   c                L   > TU    R                  5       R                  5       S   $ rW   )r  
splitlinesrj  s    r)   r   r  
	  s     d1g113>>@Cr+   c           	     |   > [        TU    R                  [        R                  " TR                  SS05      S95      $ )Ns   gitT)r   )ro  r  r   diffalloptsr  rj  s    r)   r   r  	  s1    4GLLh22477VTNKLL
r+   )
r  r  r  r  r  r  r  r  r
  r  Ns,   unexpected field name passed to matching: %sc                >   > T Vs/ s H
  o" U 5      PM     sn$ s  snf r5   r-  )r1   r   getfieldfuncss     r)   r   r  	  s    }5}!1}55s   c                   > T H<  nT" U5      nSn[        T5       H  u  pEX$   U" U 5      :w  d  M  SnM     U(       d  M<    g   gr6  )	enumerate)	r(   r/   r  r   rT   r   r&  getinfor   s	         r)   r\  matching.<locals>.matches	  sN    CS\FE!-09!$!E 1 u  r+   s   <matching%r %r>r	  )r  r   r*   r@   ra   r   splitr  r   rY  ro  sortr  r   r#   r  )r&   r'   r(   r  	fieldlistfieldsrY  r  _funcsinfogetfieldr\  r  r&  r)  r   s   `           @@@@r)   matchingr2    s   4 	1a=>?A$D)1Q40DI
1vzaDBC
 %'	 	 FK88Fg x))F	!MM%   [FV& 8z"
J# &\F
KKLK! M)-)7+/+/C
F ::dD)""AB 
 	X&  6G	 ==,>+M=NNr+   s   reverse(set)c                R    [        XX#5      nU[        :X  a  UR                  5         U$ )zReverse order of set.)r*   rb   rs  )r&   r'   r(   r"   r  s        r)   rs  rs  +	  s&     	tQ&A			Hr+   s
   roots(set)c                   ^ ^^ [        T [        T 5      U5      mT R                  R                  mUU U4S jnUTR	                  USS9-  $ )z2Changesets in set with no parent changeset in set.c                   >  T" U 5       H  nSU::  d  M  UT;   d  M    g   g! [         R                   a4    TS    R                  5        H  nUR                  5       T;   d  M     g    gf = f)Nr   FTr   r   rX  r/   )r1   rv   rX  r&   r   s     r)   r  roots.<locals>.filter:	  sn    	!QZ6a1f    	 $$ 	!$Z'')557a<  * 		!s'   # # # # <A+#A+&A+*A+s   <roots>r	  )r*   r@   rK   r   r  )r&   r'   r(   r  rX  r   s   `   @@r)   r  r  4	  sF     	t[&*Ann''G	 AHHVjH999r+   ic                6    UR                  [        [        5      $ r5   )randintMININTMAXINT)r   gens     r)   pick_randomr=  L	  s    ;;vv&&r+   c                "    U R                  5       $ r5   r  r   s    r)   r   r   S	  s
    r+   c                "    U R                  5       $ r5   r  r?  s    r)   r   r   T	  s
    q}}r+   c                "    U R                  5       $ r5   r  r?  s    r)   r   r   U	  s
    qvvxr+   c                "    U R                  5       $ r5   r  r?  s    r)   r   r   V	  s
    r+   c                (    U R                  5       S   $ rW   r  r?  s    r)   r   r   W	  s    qvvx{r+   )   revr  s   descr  r	  r  s   node   randomc                   [        U SS5      nSU;  a  [        R                  " [        S5      5      eSnSU;   a  [	        US   [        S5      5      n/ nUR                  5        Hz  nUnUR                  S5      nU(       a  US	S
 nU[        ;  a<  US:w  a6  [        R                  " [        S5      [        R                  " U5      -  5      eUR                  XF45        M|     [        U5      S	:  a6  [        S U 5       5      (       a  [        R                  " [        S5      5      e0 nSU;   a?  [        S U 5       5      (       a	  US   US'   O[        R                  " [        S5      5      eSU;   aU  [        S U 5       5      (       a  US   n[	        U[        S5      5      n	XS'   O[        R                  " [        S5      5      eUS   X74$ )z5Parse sort options into (set, [(key, reverse)], opts)s   sorts%   set keys topo.firstbranch random.seedr   s"   sort requires one or two argumentsrD  s   keyss   sort spec must be a string   -r   N   topos   unknown sort key %rc              3  0   #    U  H  u  pUS :H  v   M     g7frH  Nr-  rL  r   rs  s      r)   rM  _getsortargs.<locals>.<genexpr>x	  s      I*!g   s7   topo sort order cannot be combined with other sort keys   topo.firstbranchc              3  0   #    U  H  u  pUS :H  v   M     g7frJ  r-  rK  s      r)   rM  rL  	  s     7h
qG|hrM  s>   topo.firstbranch can only be used when using the topo sort key   random.seedc              3  0   #    U  H  u  pUS :H  v   M     g7f)rE  Nr-  rK  s      r)   rM  rL  	  s     9*!qI~rM  s   random.seed must be a strings;   random.seed can only be used when using the random sort key)r   r   r#   r   r   r+  r9  _sortkeyfuncsr   bytestrr  ra   rV  )
r(   r   r   keyflagsr   fkrs  r   r   seeds
             r)   _getsortargsrW  ]	  s   	0D
 Tq!FGHHD$g*G(HIHZZ\,,t$!"AM!a7l""()H,<,<R,@@  	%  8}qS I IIIHI
 	
 Dd"7h777(,-@(AD$% ""4  9999^$AQ"A BCD#'  ""6  <''r+   s   sort(set[, [-]key... [, ...]])c                :  ^ ^ [        U5      u  pEn[        T XU5      nU(       a
  U[        :w  a  U$ [        U5      S:X  a#  US   S   S:X  a  UR	                  US   S   S9  U$ US   S   S:X  a~  SnT R
                  R                  mTn	[        U;   a  UU 4S jn	SU;   a  [        T XS   5      n[        [        R                  " XyU5      S	S
9nUS   S   (       a  UR                  5         U$ U V
s/ s H  n
T U
   PM
     nn
[        U5       HX  u  p[        U   nUS:X  a5  SU;   a/  US   n[        R                  " U5      n
[         R"                  " XS9nUR	                  XS9  MZ     [        U Vs/ s H  nUR%                  5       PM     sn5      $ s  sn
f s  snf )a  Sort set by keys. The default sort order is ascending, specify a key
as ``-key`` to sort in descending order.

The keys can be:

- ``rev`` for the revision number,
- ``branch`` for the branch name,
- ``desc`` for the commit message (description),
- ``user`` for user name (``author`` can be used as an alias),
- ``date`` for the commit date
- ``topo`` for a reverse topographical sort
- ``node`` the nodeid of the revision
- ``random`` randomly shuffle revisions

The ``topo`` sort order cannot be combined with other sort keys. This sort
takes one optional argument, ``topo.firstbranch``, which takes a revset that
specifies what topographical branches to prioritize in the sort.

The ``random`` sort takes one optional ``random.seed`` argument to control
the pseudo-randomness of the result.
r   r   rD  )rs  rH  r-  c                   >  T" U 5      $ ! [         R                   a:    TS    R                  5        Vs/ s H  oR                  5       PM     Os  snf sns $ f = fr5   r6  )r1   rv   r   r&   s     r)   parentsfuncsort.<locals>.parentsfunc	  sR    C%a=(,, C-1$Z-?-?-AB-AEEG-ABBCs    )AA	AArN  T)istoporE  rP  )r<  )r  rs  )rW  r*   rb   ra   r,  rK   r   r   rA   r	   toposortrs  reversedrR  randomRandom	functoolspartialr/   )r&   r'   r(   r"   r   rT  r   r   firstbranchrZ  r1   ctxsr   rs  r   rV  r   r   s   `                @r)   r,  r,  	  s   2 %QA$5)Du+
8}hqk!n6		(1+a.	)	!Q7	"^^..
 d?C $& v4G/HIKNN4k:
 A;q>LLN ""TDGTD"x(
Q	>n4'Dd#A$$T1D		d	, ) T*TAEEGT*++ # +s   1F2Fs   subrepo([pattern])c                   ^ ^^^ [        USS[        S5      5      nSm[        U5      S:w  a  [        US   [        S5      5      m[        R
                  " S/5      mU4S jmUUU U4S jnUR                  US	T4S
9$ )z|Changesets that add, modify or remove the given subrepo.  If no subrepo
pattern is named, any subrepo changes are returned.
r   r   s"   subrepo takes at most one argumentNs   subrepo requires a patterns   .hgsubstatec              3  x   >#    [         R                  " T5      u  pnU  H  nU" U5      (       d  M  Uv   M     g 7fr5   )r   r  )r  r   rv   rS   r$  r   s        r)   
submatchessubrepo.<locals>.submatches	  s2     **3/aDww
 s   *:	:c                x  > TU    nTR                  UR                  5       R                  5       UR                  5       TS9nTc2  UR                  =(       d    UR                  =(       d    UR
                  $ UR                  (       a)  [        T" UR                  R                  5       5      5      $ UR                  (       a  [        UR                  5       R                  R                  5       5      nUR                  UR                  R                  5       5        T" U5       HK  nUR                  5       R                  R                  U5      UR                  R                  U5      :w  d  MK    g   UR
                  (       a7  [        T" UR                  5       R                  R                  5       5      5      $ g)N)r   TF)r  r   rW  r   r  r  rV  r   r   r   r  r  )	r(   r   r   subsr,  rS   r   r&   rg  s	        r)   r\  subrepo.<locals>.matches	  s   GKKqvvxqK9;775ajj5AII577z!**//"3455::qttv++-.DKK

)*"4(446??&&t,

t0DD ) 99z!$$&//"6"6"89::r+   s   <subrepo %r>r	  )r  r   ra   r   rQ  exactr  )r&   r'   r(   r   r\  rS   r   rg  s   `    @@@r)   subreporm  	  s{     1aACDED
C
4yA~Q#@!AB'(A . ==OS+A=BBr+   c                N  ^ U R                  5       R                  nUR                  R                  nUR                  mU" U4S jU 5       5       Vs1 s H
  oT" U5      iM     nnUR                  S5        [        R                  " X`R                  R                  -
  5      $ s  snf )z(repo, smartset, [node] -> [node]) -> smartset

Helper method to map a smartset to another smartset given a function only
talking about nodes. Handles converting between rev numbers and nodes, and
filtering.
c              3  4   >#    U  H  nT" U5      v   M     g 7fr5   r-  )rL  r1   tonodes     r)   rM  !_mapbynodefunc.<locals>.<genexpr>
  s     !7Q&))QrO  N)	
unfilteredrK   rL   get_revrW  rY  r   rA   filteredrevs)r&   r   r   r   torevrT   r  rp  s          @r)   _mapbynodefuncrv  
  s     
		$	$BHHEWWF !!7Q!7 78 71eAh 7F8
NN4F^^%@%@@AA 9s   B"s   successors(set)c                \   ^  [        T [        T 5      U5      nU 4S jn[        T X45      nX-  $ )zJAll successors for set, including the given set themselves.
(EXPERIMENTAL)c                F   > [         R                  " TR                  U 5      $ r5   )r   allsuccessorsobsstore)rH   r&   s    r)   r   successors.<locals>.<lambda> 
  s    g++DMM5Ar+   )r*   r@   rv  )r&   r'   r(   r   r   ds   `     r)   
successorsr}  
  s1     	t[&*AAAtQ"A:r+   c                   ^  [         R                  " T US9u  nm nUS:X  a*  U(       d  [        R                  " T 5      m U 4S jnOU 4S jnUT U4$ )Nr  r  c                6   > T[         R                  " U 5      ;   $ r5   re  r   r  s    r)   r   #_substringmatcher.<locals>.<lambda>,
  s    8>>!+< <r+   c                   > TU ;   $ r5   r-  r  s    r)   r   r  .
  s	    1r+   )r   r  r   r  )r  r  r  r  s   `   r)   r  r  %
  sQ    '55}D'7 znnW-G<G,G'!!r+   s   tag([name])c                   [        USS[        S5      5      nU R                  nU(       a  [        US   [        S5      5      n[        R
                  " U5      u  penUS:X  ab  U R                  R                  R                  US5      nUc"  [        R                  " [        S5      U-  5      eX   R                  5       1n	X-  $ U R                  5        V
Vs1 s H%  u  pU" U
5      (       d  M  UR                  U5      iM'     n	n
n X-  $ U R                  5        V
Vs1 s H  u  pU
S:w  d  M  UR                  U5      iM      n	n
nX-  $ s  snn
f s  snn
f )	zThe specified tag by name, or all tagged revisions if no name is given.

Pattern matching is supported for `name`. See
:hg:`help revisions.patterns`.
r   r   s   tag takes one or no argumentss$   the argument to tag must be a stringr  Ns   tag '%s' does not exists   tip)r  r   rK   r   r   r  
_tagscachetagsr  r   r0   r/   tagslist)r&   r'   r(   r   r   r  r  r  tnr   rf  rT   s               r)   tagr  2
  s6    1aA>?@D	BG56

 ",!9!9'!Bw:%%))'48Bz++01G;   A
 : (,}}Etq'!*AEA : $(==?B?41a6kYRVVAY?B: FBs   E
.E
E.Es   taggedc                    [        XU5      $ r5   )r  r   s      r)   taggedr  R
  s    tQr+   s   orphan()c                f    [        USS[        S5      5        [        R                  " U S5      nX-  $ )z?Non-obsolete changesets with obsolete ancestors. (EXPERIMENTAL)r   s   orphan takes no arguments   orphanr=  )r&   r'   r(   orphans       r)   r  r  W
  s0     Aq!Q345^^D),F?r+   s
   unstable()c                2   [        USSS5        [        5       nUR                  [        R                  " U S5      5        UR                  [        R                  " U S5      5        UR                  [        R                  " U S5      5        U[        U5      -  $ )z-Changesets with instabilities. (EXPERIMENTAL)r   s   unstable takes no argumentsr  r<  r  )r  r   r  r>  r?  rA   )r&   r'   r(   	_unstables       r)   unstabler  `
  sw     Aq!34IV^^D)45V^^D*;<=V^^D*=>?GI&&&r+   s   user(string)c                    [        XU5      $ )zUser name contains string. The match is case-insensitive.

Pattern matching is supported for `string`. See
:hg:`help revisions.patterns`.
)r  r   s      r)   r  r  l
  s     $""r+   s   wdir()c                    [        USS[        S5      5        [        U;   d  [        U[        5      (       a  [        [        /5      $ [        5       $ )z!Working directory. (EXPERIMENTAL)r   s   wdir takes no arguments)r  r   r   r?   r@   rA   r   s      r)   wdirr  v
  sA     Aq!Q123&Jv{;;y!!9r+   c                   [        US5      nU(       d
  [        5       $ U R                  n/ n[        5       nUR	                  S5       H|  n [        U5      nSU-  U:w  d  X;  a  [        eU/n	U	 HP  nX;   a  M
  X;   d  U[        ;   a&  [        U[        5      (       a  UR                  U5        UR                  U5        MR     M~     [        U5      $ ! [         a    [        XU[        5      n	 Nf = f)N   internal error    s   %d)r   rA   rK   r   r+  r  rw  rB   rb   r>   r?   r@   r  r   )
r&   r'   r(   r   r   rU  seenrf  r1   r   s
             r)   _orderedlistr  
  s    !&'Ay 
B	B5DWWU^	;AA	a1;  3D Ay$v{33		!HHQK  ( 2;  	;T1k:D	;s   "CC0/C0s   _listc                `    U[         :X  a  U[        U [        U 5      U5      -  $ [        XU5      $ r5   )rD   r  r@   r%   s       r)   _listr  
  s0    T;t+<a@@@D!,,r+   c                    [        US5      nU(       d
  [        5       $ UR                  S5       Vs/ s H  n[        U5      PM     nnUn[        U Vs/ s H  oDU;   d  M
  UPM     sn5      $ s  snf s  snf Nr  r  )r   rA   r+  r  )r&   r'   r(   r   r1   rU  s         r)   _orderedintlistr  
  se    !&'Ay''%.	).Q#a&.B	)Ar,r!!VAr,-- 
*,s   A-	A2 A2s   _intlistc                `    U[         :X  a  U[        U [        U 5      U5      -  $ [        XU5      $ r5   )rD   r  r@   r%   s       r)   _intlistr  
  0    k$.?CCCtQ//r+   c                "   [        US5      nU(       d
  [        5       $ U R                  nUR                  S5       Vs/ s H  oTR	                  [        U5      5      PM     nnUn[        U Vs/ s H  oUU;   d  M
  UPM     sn5      $ s  snf s  snf r  )r   rA   rK   r+  r/   r   )r&   r'   r(   r   r   r1   rU  s          r)   _orderedhexlistr  
  st    !&'Ay	B"#''%.	1.Q&&Q..B	1Ar,r!!VAr,-- 
2,s   #B-	B:Bs   _hexlistc                `    U[         :X  a  U[        U [        U 5      U5      -  $ [        XU5      $ r5   )rD   r  r@   r%   s       r)   _hexlistr  
  r  r+   s   ranger   s   rangepres	   rangeposts   dagrangerM  s   symbols   ands	   andsmally   ors   nots
   differences   relations   relsubscripts	   subscript   lists   keyvalue)s   funcs   ancestors   parents
   parentposts   smartsets   nodeset)   gs   generationsc                   ^  U 4S jnU$ )Nc                   >  [         R                  " TU 5      $ ! [        R                   a    [        R                  " SU -  5      ef = f)Ns!   ambiguous revision identifier: %s)r   isrevsymbolr   AmbiguousPrefixLookupError
InputError)symbolr&   s    r)   r   lookupfn.<locals>.fn
  sK    	&&tV44// 	""4v= 	s	    .Ar-  )r&   r   s   ` r)   lookupfnr  
  s     Ir+   c                    [        X/US9$ )z+Create a matcher for a single revision spec)r  )matchany)r  specr  s      r)   r   r     s    Bv..r+   c                  ^ U(       d  SS jnU$ [        U5      (       d  [        R                  " [        S5      5      e[	        U5      S:X  a  [
        R                  " US   T5      nOSS[        U4S jU 5       5      -   4n/ nSnU (       a,  UR                  U R                  S	5      5        U R                  nU(       a  UR                  UR                  5       5        U(       a  [
        R                  " XVUS
9n[
        R                  " U5      n[
        R                  " U5      n[
        R                  " U5      n[!        U5      $ )aM  Create a matcher that will include any revisions matching one of the
given specs

If lookup function is not None, the parser will first attempt to handle
old-style ranges, which may contain operator characters.

If localalias is not None, it is a dict {name: definitionstring}. It takes
precedence over [revsetalias] config section.
Nc                    [        5       $ r5   )rA   )r&   r'   s     r)   mfuncmatchany.<locals>.mfunc  s
    9r+   s   empty queryr   r   r  )r  c              3  R   >#    U  H  n[         R                  " UT5      v   M     g 7fr5   )r   parse)rL  r   r  s     r)   rM  matchany.<locals>.<genexpr>  s!     JEqz//6::Es   $'s   revsetalias)warnr5   )allr   r#   r   ra   r   r  tupler   configitemsr  r   expandaliases
foldconcatanalyzeoptimizemakematcher)r  specsr  
localaliasr  treealiasesr  s     `     r)   r  r    s    	 u::q011
5zQa&1 JEJJJ

 GD	r~~n56wwz'')*''DA  &Dd#Dt$Dtr+   c                   ^  SU 4S jjnU$ )z)Create a matcher from an evaluatable treec                `   > Uc  Uc  [         nO[        nUc  [        U 5      n[        XTU5      $ r5   )rb   rD   r@   r*   )r&   r'   r"   r  s      r)   r  makematcher.<locals>.mfunc3  s5    =~##> &FdD%00r+   r   r-  )r  r  s   ` r)   r  r  0  s    1 Lr+   c                    UR                   R                  5        H6  u  p4U[        U'   UR                  (       d  M!  [        R                  U5        M8     g)z2Load revset predicates from specified registrarobjN)_tabler   r   _safesafesymbolsr   )r  extnameregistrarobjr$  r   s        r)   loadpredicater  @  s;    "))//1
:::OOD! 2r+   )FNN)F)Tr5   r   )
__future__r   r  ra  r_  r  i18nr   rW  r   r   r   rx  r	   r
   r   r   r   r   r  r   r   rQ  r   r>  r   r   r   r   r   r   r   r   r   r   r  r   utilsr   r   r   r   r   r   r  rz   r   r  r   rA   r  r`   r@   r>   ri   rb   rD   r*   r3   r:   rB   rE   rI   rG   rU   rY   r[   r]   rO   rf   rl   rn   rr   ru   r{   r}   r   r   r   r   r   r   r   r   r   r   r   r  r  	predicater   r   r   r   r   r   r   r   r   r  r  r  r%  r(  r@  rE  r   re  r   rl  rr  rt  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r  r.   r  rP   r  r  r  r#  r1  r3  rK  rN  rV  r   ra  rj  r  rQ   ry  r  r  rc  r  r  r(  r  r  r  r  r  r   rd  r  rX  r  r  r  r  r  r  r  r  r  r  r  r  r/   r  r2  rs  r  r;  r:  r=  r<   binnoderR  rW  r,  rm  rv  r}  r  r  r  r  r  r  r  r  r  r  r  r  r  r$   r   r   r  r  r  r  r  i18nfunctionsr-  r+   r)   <module>r     s   #    	  
     ,    	  	""
""



$$


$$


$$


"" !P 
 #. <>/CJ
;&CCN36	1!>=
<	1HM+, 


 e%%'	 >  =M M $r2	3 3	3 "c: ;, DH %D1 2> D)9 *9(* 43 4 4( )& ;T"# ## T*" +"J #$r:0 ;0f T*	# +	# ;T"	 #	"J" $' ( ;T"- . 'd3	" 4	" ". / D) * D) * ,D -D6 D) *0 43 4 ?b1 2" DH 'd3 4B d+; ,;  tB7, 8,^ #C0&M 1&MR  t,% -% %DDA( B(V E#6
" 7
" <d# $ #$/ 0B T*< +<~ DDC) D)
6 (t4/ 5/ ?&G 'G F	B	BJ  !( "(0 8$"  " >"%G &G. >%W &Wt $r2
? 3
? 94   !  =tt4 5( ;T" # D4B 5B( 'dd1M N. 448 9& ;T"; #; :D!7 "7 $' (( ;T"; #; d26	6 7	6 "  "J, =t$ % 94  ! =t$ % T* +: $' (@ U26) 7)X <d# $* <d# $6 4( )(=
 >%= &=
 >%( &( :D!( "( ;T"( #( $' (D ?6 7 =t$; %; 0t< =< ;T"/ #/ "/  0 F T"5	5 6	5 >% & ?&! '!$ >5* 6* *6~O 7~OB ?a@ A =t$: %:& 

1  ' NN#&!"__	<(~ %DD=,=,@  !)C ")CXB D) *
" >% &> 94   !  ;T" # =t$' %' ?b1# 2# 94* +B 8$$/- 0-. ;TT!<0 =0. ;TT20 30h  )	
  y y F , 
5 F =  _ ,  W!" #$ /6 "	 % 	/
&R " dD) $  r+   