tzh
2024-08-22 c7d0944258c7d0943aa7b2211498fd612971ce27
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
L\¬Qc@sadZddlZddddgZiZdZd„Zd    „Zd
„Zd „Zd „Z    dS( s£Filename matching with shell patterns.
 
fnmatch(FILENAME, PATTERN) matches according to the local convention.
fnmatchcase(FILENAME, PATTERN) always takes case in account.
 
The functions operate by translating the pattern into a regular
expression.  They cache the compiled regular expressions for speed.
 
The function translate(PATTERN) returns a regular expression
corresponding to PATTERN.  (It does not compile it.)
iÿÿÿÿNtfiltertfnmatcht fnmatchcaset    translateidcCstjƒdS(sClear the pattern cacheN(t_cachetclear(((sO/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/fnmatch.pyt_purgescCs=ddl}|jj|ƒ}|jj|ƒ}t||ƒS(s½Test whether FILENAME matches PATTERN.
 
    Patterns are Unix shell style:
 
    *       matches everything
    ?       matches any single character
    [seq]   matches any character in seq
    [!seq]  matches any char not in seq
 
    An initial period in FILENAME is not special.
    Both FILENAME and PATTERN are first case-normalized
    if the operating system requires it.
    If you don't want this, use fnmatchcase(FILENAME, PATTERN).
    iÿÿÿÿN(tostpathtnormcaseR(tnametpatR((sO/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/fnmatch.pyRs cCsddl}ddl}g}|jj|ƒ}|tkr}t|ƒ}ttƒtkrgtjƒnt    j
|ƒt|<nt|j }|j|krÉxf|D]"}||ƒr |j |ƒq q Wn9x6|D].}||jj|ƒƒrÐ|j |ƒqÐqÐW|S(s2Return the subset of the list NAMES that match PATiÿÿÿÿN( Rt    posixpathRR    RRtlent    _MAXCACHERtretcompiletmatchtappend(tnamesR RR tresulttresRR
((sO/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/fnmatch.pyR-s"       cCsd|tkrMt|ƒ}ttƒtkr7tjƒntj|ƒt|<nt|j|ƒdk    S(sTest whether FILENAME matches PATTERN, including case.
 
    This is a version of fnmatch() which doesn't case-normalize
    its arguments.
    N(    RRR RRRRRtNone(R
R R((sO/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/fnmatch.pyRCs    cCs«dt|ƒ}}d}x‡||kr¢||}|d}|dkrU|d}q|dkrn|d}q|dkrŒ|}||kr©||d    kr©|d}n||krÒ||d
krÒ|d}nx*||krþ||d
krþ|d}qÕW||kr|d }qŸ|||!jd d ƒ}|d}|dd    kr\d|d}n|ddkryd |}nd||f}q|tj|ƒ}qW|dS(sfTranslate a shell PATTERN to a regular expression.
 
    There is no way to quote meta-characters.
    itit*s.*t?t.t[t!t]s\[s\s\\t^s%s[%s]s\Z(?ms)(R treplaceRtescape(R titnRtctjtstuff((sO/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/fnmatch.pyRQs8
 
 
 (
t__doc__Rt__all__RRRRRRR(((sO/tmp/ndk-User/buildhost/install/prebuilt/darwin-x86_64/lib/python2.7/fnmatch.pyt<module> s