AlkantarClanX12

Your IP : 3.138.114.140


Current Path : /proc/self/root/usr/lib64/python3.8/lib2to3/__pycache__/
Upload File :
Current File : //proc/self/root/usr/lib64/python3.8/lib2to3/__pycache__/fixer_base.cpython-38.opt-2.pyc

U

e5d"�@sPddlZddlmZddlmZddlmZGdd�de�ZGdd	�d	e�Z	dS)
�N�)�PatternCompiler)�pygram)�does_tree_importc@s�eZdZdZdZdZdZdZe�	d�Z
e�ZdZ
dZdZdZdZdZejZdd�Zdd	�Zd
d�Zdd
�Zdd�Zddd�Zdd�Zddd�Zdd�Zdd�Zdd�Z dS)�BaseFixNrZpostF�cCs||_||_|��dS�N)�options�log�compile_pattern)�selfr	r
�r
�*/usr/lib64/python3.8/lib2to3/fixer_base.py�__init__/szBaseFix.__init__cCs,|jdk	r(t�}|j|jdd�\|_|_dS)NT)Z	with_tree)�PATTERNrr�pattern�pattern_tree)rZPCr
r
rr;s

�zBaseFix.compile_patterncCs
||_dSr)�filename)rrr
r
r�set_filenameFszBaseFix.set_filenamecCsd|i}|j�||�o|S)N�node)r�match�rrZresultsr
r
rrMs	z
BaseFix.matchcCs
t��dSr)�NotImplementedErrorrr
r
r�	transformYszBaseFix.transform�xxx_todo_changemecCs2|}||jkr"|tt|j��}q|j�|�|Sr)�
used_names�str�next�numbers�add)r�template�namer
r
r�new_nameis

zBaseFix.new_namecCs.|jrd|_|j�d|j�|j�|�dS)NFz### In file %s ###)�	first_logr
�appendr)r�messager
r
r�log_messagetszBaseFix.log_messagecCs>|��}|��}d|_d}|�|||f�|r:|�|�dS)N�zLine %d: could not convert: %s)�
get_linenoZclone�prefixr&)rr�reason�linenoZ
for_output�msgr
r
r�cannot_convertzszBaseFix.cannot_convertcCs|��}|�d||f�dS)NzLine %d: %s)r(r&)rrr*r+r
r
r�warning�szBaseFix.warningcCs(|j|_|�|�t�d�|_d|_dS)NrT)rr�	itertools�countrr#�rZtreerr
r
r�
start_tree�s
zBaseFix.start_treecCsdSrr
r1r
r
r�finish_tree�szBaseFix.finish_tree)r)N)!�__name__�
__module__�__qualname__rrrr	rr/r0r�setr�orderZexplicitZ	run_orderZ_accept_typeZkeep_line_orderZ
BM_compatiblerZpython_symbolsZsymsrrrrrr"r&r-r.r2r3r
r
r
rrs2




rcs(eZdZdZ�fdd�Zdd�Z�ZS)�ConditionalFixNcstt|�j|�d|_dSr)�superr9r2�_should_skip)r�args��	__class__r
rr2�szConditionalFix.start_treecCsJ|jdk	r|jS|j�d�}|d}d�|dd��}t|||�|_|jS)N�.���)r;�skip_on�split�joinr)rrZpkgr!r
r
r�should_skip�s
zConditionalFix.should_skip)r4r5r6rAr2rD�
__classcell__r
r
r=rr9�sr9)
r/Zpatcomprr'rZ
fixer_utilr�objectrr9r
r
r
r�<module>s