o
    ,]C
                     @   s0  d dl mZ d dlZd dlmZmZmZ erd dlmZ nd dl	mZ erZd dl
Z
d dl	mZ dd Zd dlmZ dd	 Zd
d Zd dlmZ dd ZeZd dlmZ eZeZeZn+d dlZd dlmZ ejZejZejZejZejZejZejZejZejZejZejZerdddZerg dZdS g ZdS )    )unicode_literalsN)PY2PY3exec_)Mappingc                 O   s   | |i |S )N )fargskwr   r   4/usr/lib/python3/dist-packages/past/builtins/misc.pyapply   s   r   )strc                 C   s   t t| fS )zU
        Return a byte-string of one character with ordinal i; 0 <= i <= 256
        )oldstrbytes)ir   r   r   chr   s   r   c                 C   s   | |k| |k  S )zf
        cmp(x, y) -> integer

        Return negative if x<y, zero if x==y, positive if x>y.
        r   )xyr   r   r   cmp   s   r   )internc                 C   s   dt | dd  S )zUoct(number) -> string

        Return the octal representation of an integer
        0   N)builtinsoct)numberr   r   r   r   %   s   r   )reloadc                 C   s   |du rt  d }|d j}|d j}n|du r|}t|ts$tdt|ts-tdt| d}| }W d   n1 sAw   Y  t	|| d}t
||| dS )z
        Read and execute a Python script from a file in the given namespaces.
        The globals and locals are dictionaries, defaulting to the current
        globals and locals. If only globals is given, locals defaults to it.
        N   r   zglobals must be a mappingzlocals must be a mappingrbexec)inspectstack	f_globalsf_locals
isinstancer   	TypeErroropenreadcompiler   )filename	myglobalsmylocalscaller_framefinsourcecoder   r   r   execfileB   s   



r/   )
r   r   r   r/   r   	raw_inputr   unichrunicodexrange)NN)
__future__r   r   future.utilsr   r   r   collectionsr   collections.abcr   r   past.builtinsr   r   r   r   sysr   r   inputr0   impr   r2   r1   ranger3   __builtin__r/   __all__r   r   r   r   <module>   sL    
