Your IP : 18.188.245.152


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_print.cpython-33.pyo

�
��f&c@s�dZddlmZddlmZddlmZddlmZddlmZm	Z	m
Z
mZmZej
d�ZGdd	�d	ej�Zd
S(uFixer for print.

Change:
    'print'          into 'print()'
    'print ...'      into 'print(...)'
    'print ... ,'    into 'print(..., end=" ")'
    'print >>x, ...' into 'print(..., file=x)'

No changes are applied if print_function is imported from __future__

i(upatcomp(upytree(utoken(u
fixer_base(uNameuCalluCommauStringuis_tupleu"atom< '(' [atom|STRING|NAME] ')' >cBs8|EeZdZdZdZdd�Zdd�ZdS(uFixPrintuP
              simple_stmt< any* bare='print' any* > | print_stmt
              c
Cs�|jd�}|r>|jttd�gd|j��dS|jdd�}t|�dkrztj|d�rzdSd}}}|r�|dt
�kr�|dd�}d}n|r|dtjt
jd�kr|dj�}|dd�}nd	d
�|D�}|r+d|d_n|dk	sO|dk	sO|dk	r�|dk	r}|j|dtt|���n|dk	r�|j|d
tt|���n|dk	r�|j|d|�q�nttd�|�}	|j|	_|	S(Nubareuprintuprefixiiu u>>icSsg|]}|j��qS((uclone(u.0uarg((u</opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_print.pyu
<listcomp>?s	u&FixPrint.transform.<locals>.<listcomp>uusepuendufilei����i����(ugetureplaceuCalluNameuprefixuchildrenulenuparend_exprumatchuNoneuCommaupytreeuLeafutokenu
RIGHTSHIFTucloneu	add_kwarguStringurepr(
uselfunodeuresultsu
bare_printuargsusepuendufileul_argsun_stmt((u</opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_print.pyu	transform%s8
%	%$""uFixPrint.transformcCsrd|_tj|jjt|�tjtjd�|f�}|ra|j	t
��d|_n|j	|�dS(Nuu=u (uprefixupytreeuNodeusymsuargumentuNameuLeafutokenuEQUALuappenduComma(uselful_nodesus_kwdun_expru
n_argument((u</opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_print.pyu	add_kwargMs		uFixPrint.add_kwargNT(u__name__u
__module__u__qualname__uTrueu
BM_compatibleuPATTERNu	transformu	add_kwarg(u
__locals__((u</opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_print.pyuFixPrints(uFixPrintN(u__doc__uupatcompupytreeupgen2utokenu
fixer_baseu
fixer_utiluNameuCalluCommauStringuis_tupleucompile_patternuparend_expruBaseFixuFixPrint(((u</opt/alt/python33/lib64/python3.3/lib2to3/fixes/fix_print.pyu<module>s(	

?>