/opt/alt/python37/lib64/python3.7/lib2to3/__pycache__
B ��� (�� @ sx d dl mZ d dlmZmZ d dlmZmZ eZeZ ej ZeZdZ dZdZG dd� de�Zdd d�Zdd � Zdd� Zd S )� )�pytree)�grammar�token)�pattern_symbols�python_symbols���������c @ s6 e Zd Zddd�Zdd� Zdd� Zdd � Zd d� ZdS ) �MinNodeNc C s. || _ || _g | _d| _d | _g | _g | _d S )NF)�type�name�children�leaf�parent�alternatives�group)�selfr r � r �6/opt/alt/python37/lib64/python3.7/lib2to3/btm_utils.py�__init__ s zMinNode.__init__c C s t | j�d t | j� S )N� )�strr r )r r r r �__repr__ s zMinNode.__repr__c C s� | }g }x�|r�|j tkr`|j�|� t|j�t|j�krTt|j�g}g |_|j}q n|j}d }P |j tkr�|j �|� t|j �t|j�kr�t |j �}g |_ |j}q n|j}d }P |j tjkr�|j r�|�|j � n|�|j � |j}q W |S )N)r �TYPE_ALTERNATIVESr �append�lenr �tupler � TYPE_GROUPr �get_characteristic_subpattern�token_labels�NAMEr )r �node�subpr r r �leaf_to_root! s8 zMinNode.leaf_to_rootc C s&