Sindbad~EG File Manager
a
��gS2 � @ s� d Z ddlmZ ddlZddlmZ eejej d �Z eejd �Z
dd� ed�D �Zd d� ed�D �Z
G d
d� d�Zedkr�dd
lmZ eddd� dS )z�Provide advanced parsing abilities for ParenMatch and other extensions.
HyperParser uses PyParser. PyParser mostly gives information on the
proper indentation of code. HyperParser gives additional information on
the structure of code.
� )� iskeywordN)�pyparse�_c C s g | ]}t |�tv �qS � )�chr�_ASCII_ID_CHARS��.0�xr r �//usr/local/lib/python3.9/idlelib/hyperparser.py�
<listcomp> � r � c C s g | ]}t |�tv �qS r )r �_ASCII_ID_FIRST_CHARSr r r r r r
c @ sZ e Zd Zdd� Zdd� Zdd� Zdd� Zddd�Zeh d
��Z e
dd� �ZdZdd� Z
dS )�HyperParserc
sH |� _ |j � _}t�|j|j�}dd� }||�|��}|js�|jD ]`}t || d�}t
|�d } d| }
|�|�| |
�d � |�
|�| ��}|dus�|dkrD q�qD|�|p�d� nF|�d |�}|r�|d } nd
} d| }
|�|�| |
�d � |�d� |jdd� � _|
� _|�� � _� fdd
�tt� j��D �� _� �|� dS )z;To initialize, analyze the surroundings of the given index.c S s t t| ��S )N)�int�float)�indexr r r �
index2line"