ó
¡¼™\c           @   sX   d  d l  m Z d  d l m Z m Z m Z d e f d „  ƒ  YZ e ƒ  Z e e _ d S(   iÿÿÿÿ(   t   SymPyDeprecationWarning(   t	   BasicMetat   Registryt   all_classest   ClassRegistryc           B   s>   e  Z d  Z g  Z d „  Z d „  Z d „  Z e d „  ƒ Z RS(   s2  
    Namespace for SymPy classes

    This is needed to avoid problems with cyclic imports.
    To get a SymPy class, use `C.<class_name>` e.g. `C.Rational`, `C.Add`.

    For performance reasons, this is coupled with a set `all_classes` holding
    the classes, which should not be modified directly.
    c         C   s$   t  j |  | | ƒ t j | ƒ d  S(   N(   R   t   __setattr__R   t   add(   t   selft   namet   cls(    (    s>   lib/python2.7/site-packages/sympy/deprecated/class_registry.pyR      s    c         C   sK   t  |  | ƒ } t j |  | ƒ | |  j j j ƒ  k rG t j | ƒ n  d  S(   N(   t   getattrR   t   __delattr__t	   __class__t   __dict__t
   itervaluesR   t   remove(   R   R   R	   (    (    s>   lib/python2.7/site-packages/sympy/deprecated/class_registry.pyR      s    c            sZ   ˆ  d k r@ t  d d d d d d d d	 d
 d ƒ j d d ƒ n  t ‡  f d †  t Dƒ ƒ S(   Nt   __wrapped__t   features%   C, including its class ClassRegistry,t   last_supported_versions   1.0t
   useinsteads'   direct imports from the defining modulet   issuei›$  t   deprecated_since_versiont
   stackleveli   c         3   s   |  ] } | j  ˆ  k Vq d  S(   N(   t   __name__(   t   .0R	   (   R   (    s>   lib/python2.7/site-packages/sympy/deprecated/class_registry.pys	   <genexpr>(   s    (   R    t   warnt   anyR   (   R   R   (    (   R   s>   lib/python2.7/site-packages/sympy/deprecated/class_registry.pyt   __getattr__   s    c         C   s   t  d ƒ ‚ d  S(   Ns#   name 'C' is not defined as a Symbol(   t	   NameError(   R   (    (    s>   lib/python2.7/site-packages/sympy/deprecated/class_registry.pyt   _sympy_*   s    (	   R   t
   __module__t   __doc__t	   __slots__R   R   R   t   propertyR   (    (    (    s>   lib/python2.7/site-packages/sympy/deprecated/class_registry.pyR      s   				N(   t   sympy.utilities.exceptionsR    t   sympy.core.coreR   R   R   R   t   C(    (    (    s>   lib/python2.7/site-packages/sympy/deprecated/class_registry.pyt   <module>   s   -	