ЀV)OSrSSKrSSKJrJr SSKrSSKr/SQrSr\R\R"\R\RS9"SS 555r \R=rrS%S jrS%S jrS%S jr"S S\5r\"5r\\S.SjrS\l\\S.SjrS\l\\S.SjrS\lS%SjrS%SjrS%SjrSrSVs0sHoS\"U5-_M snrSr \!"\R8"SS55r"\!"\R8"SS5R!S55r#0r$0r%Sr&Sr'\'\&:deS r(\RR"\&5S!5r*SSK+r+S"r,\+RZ"\"\,\(5 "S#S$5r.gs snf)&aSupport for regular expressions (RE). This module provides regular expression matching operations similar to those found in Perl. It supports both 8-bit and Unicode strings; both the pattern and the strings being processed can contain null bytes and characters outside the US ASCII range. Regular expressions can contain both special and ordinary characters. Most ordinary characters, like "A", "a", or "0", are the simplest regular expressions; they simply match themselves. You can concatenate ordinary characters, so last matches the string 'last'. The special characters are: "." Matches any character except a newline. "^" Matches the start of the string. "$" Matches the end of the string or just before the newline at the end of the string. "*" Matches 0 or more (greedy) repetitions of the preceding RE. Greedy means that it will match as many repetitions as possible. "+" Matches 1 or more (greedy) repetitions of the preceding RE. "?" Matches 0 or 1 (greedy) of the preceding RE. *?,+?,?? Non-greedy versions of the previous three special characters. {m,n} Matches from m to n repetitions of the preceding RE. {m,n}? Non-greedy version of the above. "\\" Either escapes special characters or signals a special sequence. [] Indicates a set of characters. A "^" as the first character indicates a complementing set. "|" A|B, creates an RE that will match either A or B. (...) Matches the RE inside the parentheses. The contents can be retrieved or matched later in the string. (?aiLmsux) The letters set the corresponding flags defined below. (?:...) Non-grouping version of regular parentheses. (?P...) The substring matched by the group is accessible by name. (?P=name) Matches the text matched earlier by the group named name. (?#...) A comment; ignored. (?=...) Matches if ... matches next, but doesn't consume the string. (?!...) Matches if ... doesn't match next. (?<=...) Matches if preceded by ... (must be fixed length). (?rr?s r<rrs G # - -f 55r;c6[X5RU5$)zpScan through string looking for a match to the pattern, returning a Match object, or None if no match was found.)r>rr?s r<rrs G # * *6 22r;c\rSrSrSrg) _ZeroSentinelr(N)r)r*r+r,r:r(r;r<rFrFsr;rF)countrBc$U(aoU[La [S5eUtp5U(a8U[La [S5eUtpEU(a[SS[U5--5eSSKnUR S[ SS 9 [ X5RXU5$) aFReturn the string obtained by replacing the leftmost non-overlapping occurrences of the pattern in string by the replacement repl. repl can be either a string or a callable; if a string, backslash escapes in it are processed. If it is a callable, it's passed the Match object and must return a replacement string to be used.z.sub() got multiple values for argument 'count'z.sub() got multiple values for argument 'flags'z>sub() takes from 3 to 5 positional arguments but %d were givenrN('count' is passed as positional argument stacklevel)_zero_sentinel TypeErrorlenwarningswarnDeprecationWarningr>r r@replrArHrBargsrRs r<r r s  &LM M  N* PQQLE!4783t9}!FGG  6 1  G # ' 'e <r rUs r<r r s  &MN N  N* QRRLE!4783t9}!FGG  6 1  G # ( (u ==r;)maxsplitrBc"U(aoU[La [S5eUtp$U(a8U[La [S5eUtp4U(a[SS[U5--5eSSKnUR S[ SS 9 [ X5RX5$) aSplit the source string by the occurrences of the pattern, returning a list containing the resulting substrings. If capturing parentheses are used in pattern, then the text of all groups in the pattern are also returned as part of the resulting list. If maxsplit is nonzero, at most maxsplit splits occur, and the remainder of the string is returned as the final element of the list.z3split() got multiple values for argument 'maxsplit'z0split() got multiple values for argument 'flags'z@split() takes from 2 to 4 positional arguments but %d were givenrNz+'maxsplit' is passed as positional argumentrLrM)rOrPrQrRrSrTr>r )r@rArYrBrWrRs r<r r s > )QR R N* RSSLE!4783t9}!FGG  9 1  G # ) )& ;;r;z&(pattern, string, maxsplit=0, flags=0)c6[X5RU5$)aReturn a list of all non-overlapping matches in the string. If one or more capturing groups are present in the pattern, return a list of groups; this will be a list of tuples if the pattern has more than one group. Empty matches are included in the result.)r>r r?s r<r r s G # + +F 33r;c6[X5RU5$)zReturn an iterator over all non-overlapping matches in the string. For each match, the iterator returns a Match object. Empty matches are included in the result.)r>r r?s r<r r s G # , ,V 44r;c[X5$)zACompile a regular expression pattern, returning a Pattern object.)r>)r@rBs r<rrs G ##r;c|[R5 [R5 [R 5 g)z#Clear the regular expression cachesN)_cacheclear_cache2_compile_template cache_clearr(r;r<rr#s  LLN MMO!!#r;s()[]{}?*+-|^$\.&~# \c[U[5(aUR[5$[US5nUR[5R S5$)z( Escape special characters in a string. latin1) isinstancestr translate_special_chars_mapencode)r@s r<rr1sL'3  !344gx(  !34;;HEEr;ic0[U[5(a URn[[ U5X4$![ a Of=f[ U5X4n[ RUS5nUc[U[5(aU(a [S5eU$[R"U5(d [S5e[R"X5nU[-(aU$[[ 5[ :a:[ [#[%[ 55 O![&[([ 4a Of=fU[ U'[[5[*:a:[[#[%[55 O![&[([ 4a Of=fU[U'U$)Nz5cannot process flags argument with a compiled patternz1first argument must be string or compiled pattern)rhr#valuerbtypeKeyErrorr`popr ValueErrorrisstringrPrr5rQ _MAXCACHEnextiter StopIteration RuntimeError _MAXCACHE2)r@rBkeyps r<r>r>JsW%##  tG}g455     =' )C 3Ay gw ' ' KMMN!!'**OP P   g - 5=H v;) #  4V -.!<:  F3K 7|z! T']+,|X6   GCL Hs37 AA:DD0/D0E22F  F cX[R"U[R"X55$N)_sretemplaterparse_template)r@rVs r<rcrcvs  =='"8"8"G HHr;c>[URUR44$r)r>r@rB)r}s r<_picklers aii) ))r;c$\rSrSrSSjrSrSrg)ScannericSSKJnJn [U[5(a UR nXl/n[R"5nX&l UHiupxUR5n UR[R"UXISS[R"Xr544/55 URXS5 Mk [R"XcSU44/5n[R "U5Ulg)Nr)BRANCH SUBPATTERNr) _constantsrrrhr#rplexiconrStaterB opengroupappend SubPatternparse closegrouprrscanner) selfrrBrrr}sphraseactiongids r<__init__Scanner.__init__s2 eY ' 'KKE  MMO%NF++-C HHW''1av)EFG,  LLe $ &   qT1I#6"7 8 ((+ r;cx/nURnURRU5RnSnU"5nU(dOpUR5nXW:XaOZURUR S- Sn[ U5(aX`lU"XR55nUbU"U5 UnMX!US4$)Nrr)rrrendr lastindexcallablegroup) rrAresultrrimjrs r<scan Scanner.scans $$V,22 AAv\\!++a-03F ggi0!vAabz!!r;)rrrNr)r)r*r+r,rrr:r(r;r<rrs ,""r;rr)/__doc__enumrmrr functoolsr__all__ __version__ global_enum _simple_enumIntFlagKEEPr#r$rrrrintrFrOr __text_signature__r r r r rrchrrkrrqrrr`rbrvr{r> lru_cacherccopyregrpickler)rs0r<rs"jX    4<<$))4  5 !--- u 2 6 3  C ,:.=4E-;>>8F+9<6D45$$1RR0Q1A&0QRF y  Q' ( Y  r1 % + +B /0     I* X YI I *w* %"%"qSsE=