Your IP : 52.14.49.59


Current Path : /opt/alt/python33/lib64/python3.3/lib2to3/fixes/__pycache__/
Upload File :
Current File : //opt/alt/python33/lib64/python3.3/lib2to3/fixes/__pycache__/fix_exitfunc.cpython-33.pyc

�
��f�	c@sgdZddlmZmZddlmZmZmZmZm	Z	m
Z
Gdd�dej�ZdS(u7
Convert use of sys.exitfunc to use the atexit module.
i(upytreeu
fixer_base(uNameuAttruCalluCommauNewlineusymscsV|EeZdZdZdZdZ�fdd�Z�fdd�Zdd�Z	�S(	uFixExitfuncu�
              (
                  sys_import=import_name<'import'
                      ('sys'
                      |
                      dotted_as_names< (any ',')* 'sys' (',' any)* >
                      )
                  >
              |
                  expr_stmt<
                      power< 'sys' trailer< '.' 'exitfunc' > >
                  '=' func=any >
              )
              cstt|�j|�dS(N(usuperuFixExitfuncu__init__(uselfuargs(u	__class__(u?/opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_exitfunc.pyu__init__suFixExitfunc.__init__cs&tt|�j||�d|_dS(N(usuperuFixExitfuncu
start_treeuNoneu
sys_import(uselfutreeufilename(u	__class__(u?/opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_exitfunc.pyu
start_tree!suFixExitfunc.start_treecCs�d|kr/|jdkr+|d|_ndS|dj�}d|_tjtjtt	d�t	d���}t
||g|j�}|j|�|jdkr�|j|d�dS|jj
d}|jtjkr|jt��|jt	dd��n�|jj}|j
j|j�}|j}	tjtjt	d	�t	dd�g�}
tjtj|
g�}|j|dt��|j|d
|�dS(Nu
sys_importufuncuuatexituregisteruKCan't find sys import; Please add an atexit import at the top of your file.iu uimporti(u
sys_importuNoneucloneuprefixupytreeuNodeusymsupoweruAttruNameuCallureplaceuwarninguchildrenutypeudotted_as_namesuappend_childuCommauparentuindexuimport_nameusimple_stmtuinsert_childuNewline(uselfunodeuresultsufuncuregisterucallunamesucontaining_stmtupositionustmt_containeru
new_importunew((u?/opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_exitfunc.pyu	transform%s2	
	uFixExitfunc.transformT(
u__name__u
__module__u__qualname__uTrueukeep_line_orderu
BM_compatibleuPATTERNu__init__u
start_treeu	transform(u
__locals__((u	__class__u?/opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_exitfunc.pyuFixExitfuncsuFixExitfuncN(
u__doc__ulib2to3upytreeu
fixer_baseulib2to3.fixer_utiluNameuAttruCalluCommauNewlineusymsuBaseFixuFixExitfunc(((u?/opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_exitfunc.pyu<module>s.

?>