™N
èùO5c       s1   d  Z  k Z h  Z d „  Z d „  Z d „  Z d S(   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.)
c    s;   k  } | i i |  ƒ }  | i i | ƒ } t |  | ƒ Sd 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).
	N(   s   oss   paths   normcases   names   pats   fnmatchcase(   s   names   pats   oss1   /var/tmp/python-root/usr/lib/python1.5/fnmatch.pys   fnmatch s
     c    sO   t  i | ƒ o# t | ƒ } t i | ƒ t  | <n t  | i |  ƒ t	 j	 Sd S(   s†   Test wheter FILENAME matches PATTERN, including case.
	
	This is a version of fnmatch() which doesn't case-normalize
	its arguments.
	N(
   s   _caches   has_keys   pats	   translates   ress   res   compiles   matchs   names   None(   s   names   pats   ress1   /var/tmp/python-root/usr/lib/python1.5/fnmatch.pys   fnmatchcase& s
     c    sø  d t  |  ƒ f \ } } d } xË| | j  o½|  | } | d } | d j o | d } n‹| d j o | d } np| d j oO| } | | j  o |  | d	 j o | d } n | | j  o |  | d
 j o | d } n x- | | j  o |  | d
 j o | d } qæ W| | j o | d } n£ |  | | !} | d } | d d	 j o d | d d
 } n[ | d t  | ƒ j o
 d } n: x( | d d j o | d | d } qWd | d
 } | | } n | t i	 | ƒ } q! W| d Sd S(   sa   Translate a shell PATTERN to a regular expression.
	
	There is no way to quote meta-characters.
	i    s    i   s   *s   .*s   ?s   .s   [s   !s   ]s   \[s   [^s   ^s   \^s   $N(
   s   lens   pats   is   ns   ress   cs   js   stuffs   res   escape(   s   pats   is   ns   ress   cs   js   stuffs1   /var/tmp/python-root/usr/lib/python1.5/fnmatch.pys	   translate2 sF      

 

 N(   s   __doc__s   res   _caches   fnmatchs   fnmatchcases	   translate(    s1   /var/tmp/python-root/usr/lib/python1.5/fnmatch.pys   ? s
   		