AlkantarClanX12

Your IP : 18.191.62.68


Current Path : /proc/self/root/opt/alt/python35/lib64/python3.5/__pycache__/
Upload File :
Current File : //proc/self/root/opt/alt/python35/lib64/python3.5/__pycache__/code.cpython-35.opt-2.pyc



���]�'�@s�ddlZddlZddlZddlmZmZddddgZGdd�d�ZGdd�de�Zdddd	d�Z	e
d
kr�ej�Zej
ddd
dd�ej�Zejs�ejjr�dZndZe	e�dS)�N)�CommandCompiler�compile_command�InteractiveInterpreter�InteractiveConsole�interactrc@sdeZdZddd�Zdddd�Zdd	�Zdd
d�Zdd
�Zdd�ZdS)rNcCs7|dkrddddi}||_t�|_dS)N�__name__Z__console__�__doc__)�localsr�compile)�selfr	�r�)/opt/alt/python35/lib64/python3.5/code.py�__init__s		zInteractiveInterpreter.__init__z<input>Zsinglec
Csiy|j|||�}Wn,tttfk
rG|j|�dSYnX|dkrXdS|j|�dS)NFT)r
�
OverflowError�SyntaxError�
ValueError�showsyntaxerror�runcode)r�source�filename�symbol�coderrr
�	runsource's
	
z InteractiveInterpreter.runsourcecCsAyt||j�Wn&tk
r+�Yn|j�YnXdS)N)�execr	�
SystemExit�
showtraceback)rrrrr
rNs
zInteractiveInterpreter.runcodecCs�tj�\}}}|t_|t_|t_|r�|tkr�y|j\}\}}}}	Wntk
ruYn%Xt|||||	f�}|t_tjtj	kr�t
j||�}
|jdj
|
��ntj|||�dS)N�)�sys�exc_info�	last_type�
last_value�last_tracebackr�argsr�
excepthook�__excepthook__�	traceback�format_exception_only�write�join)rr�type�value�tb�msgZdummy_filename�lineno�offset�line�linesrrr
ras			
	z&InteractiveInterpreter.showsyntaxerrorcCs�tj�\t_t_}}|t_zjtj|d|d|j�}tjtj	krv|j
dj|��ntj|d|d|�Wdd}}XdS)Nr�r)rrrr r!r%�format_exception�tb_nextr#r$r'r()rZlast_tb�eir0rrr
r�s	 z$InteractiveInterpreter.showtracebackcCstjj|�dS)N)r�stderrr')r�datarrr
r'�szInteractiveInterpreter.write)	r�
__module__�__qualname__rrrrrr'rrrr
rs	'#c@sXeZdZdddd�Zdd�Zddd�Zd	d
�Zddd
�ZdS)rNz	<console>cCs'tj||�||_|j�dS)N)rrr�resetbuffer)rr	rrrr
r�s
	zInteractiveConsole.__init__cCs
g|_dS)N)�buffer)rrrr
r9�szInteractiveConsole.resetbufferc!CsTytjWntk
r(dt_YnXytjWntk
rQdt_YnXd}|dkr�|jdtjtj||jjf�n|r�|jdt	|��d}x�yd|r�tj}n	tj}y|j
|�}Wn tk
r	|jd�PYnX|j|�}Wq�t
k
rK|jd�|j�d}Yq�Xq�WdS)	Nz>>> z... zFType "help", "copyright", "credits" or "license" for more information.zPython %s on %s
%s
(%s)
z%s
r�
z
KeyboardInterrupt
)rZps1�AttributeErrorZps2r'�version�platform�	__class__r�str�	raw_input�EOFError�push�KeyboardInterruptr9)r�bannerZcprt�more�promptr/rrr
r�s>

		




zInteractiveConsole.interactcCsK|jj|�dj|j�}|j||j�}|sG|j�|S)Nr;)r:�appendr(rrr9)rr/rrFrrr
rC�s
zInteractiveConsole.pushrcCs
t|�S)N)�input)rrGrrr
rA�szInteractiveConsole.raw_input)rr7r8rr9rrCrArrrr
r�s
-cCsZt|�}|dk	r$||_n%yddl}Wntk
rHYnX|j|�dS)Nr)rrA�readline�ImportErrorr)rEZreadfunc�localZconsolerJrrr
rs
�__main__z-q�action�
store_true�helpz*don't print version and copyright messagesr)rr%�argparseZcodeoprr�__all__rrrr�ArgumentParser�parser�add_argument�
parse_argsr"�q�flags�quietrErrrr
�<module>s"		�k