403Webshell
Server IP : 192.158.238.246  /  Your IP : 3.14.12.254
Web Server : LiteSpeed
System : Linux uniform.iwebfusion.net 4.18.0-553.27.1.lve.1.el8.x86_64 #1 SMP Wed Nov 20 15:58:00 UTC 2024 x86_64
User : jenniferflocom ( 1321)
PHP Version : 8.1.32
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /opt/alt/python310/lib64/python3.10/lib2to3/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /opt/alt/python310/lib64/python3.10/lib2to3/__pycache__/btm_matcher.cpython-310.opt-2.pyc
o

�?Og��@sj	dZddlZddlZddlmZddlmZddlmZGdd�de	�Z
Gd	d
�d
e	�Ziadd�Z
dS)
z+George Boutsioukis <gboutsioukis@gmail.com>�N)�defaultdict�)�pytree)�reduce_treec@seZdZ	e��Zdd�ZdS)�BMNodecCs"i|_g|_ttj�|_d|_dS)N�)�transition_table�fixers�nextr�count�id�content��self�r�:/opt/alt/python310/lib64/python3.10/lib2to3/btm_matcher.py�__init__s
zBMNode.__init__N)�__name__�
__module__�__qualname__�	itertoolsrrrrrrrsrc@s6eZdZ	dd�Zdd�Zdd�Zdd�Zd	d
�ZdS)�
BottomMatchercCs0t�|_t�|_|jg|_g|_t�d�|_dS)NZRefactoringTool)	�set�matchr�rootZnodesr	�loggingZ	getLoggerZloggerrrrrrs

zBottomMatcher.__init__cCsJ	|j�|�t|j�}|��}|j||jd�}|D]}|j�|�qdS)N��start)r	�appendrZpattern_treeZget_linear_subpattern�addr)r�fixerZtreeZlinear�match_nodesZ
match_noderrr�	add_fixer%s
�zBottomMatcher.add_fixerc	Cs�	|s|gSt|dt�r1g}|dD]}|j||d�}|D]}|�|�|dd�|��qq|S|d|jvrCt�}||j|d<n|j|d}|dd�r]|j|dd�|d�}|S|g}|S)Nrrr)�
isinstance�tupler�extendrr)r�patternrr!ZalternativeZ	end_nodes�endZ	next_noderrrr1s(��zBottomMatcher.addc	Cs�	|j}tt�}|D]l}|}|rvd|_|jD]}t|tj�r(|jdkr(d|_nq|j	dkr2|j}n|j	}||j
vrM|j
|}|jD]	}||�|�qBn$|j}|j
durZ|j
jrZn||j
vrq|j
|}|jD]	}||�|�qg|j
}|sq
|S)NT�;Fr)rr�listZwas_checked�childrenr#rZLeaf�value�typerr	r�parent)	rZleavesZcurrent_ac_nodeZresultsZleafZcurrent_ast_node�childZ
node_tokenr rrr�runSsB
�



�
�


��"zBottomMatcher.runcs,	td��fdd���|j�td�dS)Nz
digraph g{csZ|j��D]%}|j|}td|j|jt|�t|j�f�|dkr&t|j��|�qdS)Nz%d -> %d [label=%s] //%sr)r�keys�printr�	type_repr�strr	r
)ZnodeZsubnode_keyZsubnode��
print_noderrr5�s
�

�z*BottomMatcher.print_ac.<locals>.print_node�})r1rrrr4r�print_ac�s

zBottomMatcher.print_acN)rrrrr"rr/r7rrrrrs"8rcCsDtsddlm}|j��D]\}}t|�tkr|t|<q
t�||�S)Nr)�python_symbols)�_type_reprsZpygramr8�__dict__�itemsr,�int�
setdefault)Ztype_numr8�name�valrrrr2�s�r2)�
__author__rr�collectionsrrrZ	btm_utilsr�objectrrr9r2rrrr�<module>s	

Youez - 2016 - github.com/yon3zu
LinuXploit