ó
^ęWc           @   sĆ   d  Z  d d l Z d d l Z d d d g Z y d d l m Z Wn e k
 r` e d  Z n Xy
 e Z Wn* e	 k
 r d d l
 m Z d	   Z n Xy e j Z Wn e k
 rÁ d
   Z n Xd S(   s/   Backports for individual classes and functions.i˙˙˙˙Nt   cache_from_sourcet   callablet   fsencode(   R    c         C   s   | r d p d } |  | S(   Nt   ct   o(    (   t   py_filet   debugt   ext(    (    ss   /private/var/folders/3n/6h2rwf155rn1m71wwyxn79n80000gn/T/pip-build-IcAT_k/pip/pip/_vendor/distlib/_backport/misc.pyR       s    (   t   Callablec         C   s   t  |  t  S(   N(   t
   isinstanceR   (   t   obj(    (    ss   /private/var/folders/3n/6h2rwf155rn1m71wwyxn79n80000gn/T/pip-build-IcAT_k/pip/pip/_vendor/distlib/_backport/misc.pyR      s    c         C   sR   t  |  t  r |  St  |  t  r5 |  j t j    St d t |   j   d  S(   Ns   expect bytes or str, not %s(	   R	   t   bytest   strt   encodet   syst   getfilesystemencodingt	   TypeErrort   typet   __name__(   t   filename(    (    ss   /private/var/folders/3n/6h2rwf155rn1m71wwyxn79n80000gn/T/pip-build-IcAT_k/pip/pip/_vendor/distlib/_backport/misc.pyR   "   s    (   t   __doc__t   osR   t   __all__t   impR    t   ImportErrort	   __debug__R   t	   NameErrort   collectionsR   R   t   AttributeError(    (    (    ss   /private/var/folders/3n/6h2rwf155rn1m71wwyxn79n80000gn/T/pip-build-IcAT_k/pip/pip/_vendor/distlib/_backport/misc.pyt   <module>   s    
