a �DOg@/ � @ s� d dl Z d dlZd dlZd dlZd dlZd dlZd dlZd dlZd dlZd dl Z dd� Z g Zdd� Zdd� Z dd � Zd d� Zdd � Zddd�Zddd�ZG dd� d�Ze� jZddd�ZdS )� Nc C s dS )Na'
--> --> � r r r �/usr/lib64/python3.9/cgitb.py�reset# s r c C s | rd| d S dS d S )Nzz� r ��textr r r �small. s r c C s | rd| d S dS d S )Nzz r r r r r r �strong4 s r c C s | rd| d S dS d S )Nzzr r r r r r �grey: s r c C s� | |v rd|| fS | |j v r,d|j | fS d|j v r~|j d }t|�ti �u rf| |v r~d|| fS nt|| �r~dt|| �fS d tfS )N�local�global�__builtins__�builtin)� f_globals�type�hasattr�getattr� __UNDEF__)�name�frame�locals�builtinsr r r �lookup@ s r c C s� g d d dt f\}}}}}t�| �D ]�\}} } }}|tjkr> q�|tjkr�| tjvr�|dkr�|t ur�t|| t �}|�|| ||f� q�t | ||�\} }|�| | |f� n"| dkr�||d 7 }|}nd\}}| }q"|S )Nr �.)Nr ) r �tokenize�generate_tokens�NEWLINE�NAME�keyword�kwlistr �appendr )�readerr r �varsZ lasttoken�parent�prefix�valueZttype�token�start�end�line�wherer r r �scanvarsP s r+ � c " s� | \}}}t |t�r|j}dtj�� d d tj }t�t�� �}dt j �dtt j � t|��� dd|d | � d }d td� d }g } t�||�} | D �]F\}� }} }}� r�tj�� �� d � t j � � �f }nd � }t�|�\}}}}d}| dk�r8dtt j � | �� }| dk�r8|tj||||dd� d�7 }i �|gf� �fdd� }t|||�}dd||f g}|d u�r || }|D ]�}tddtt|�� t|� �d }|�v �r�d|t j �|�f }|�d| � n&d|t j �|�f }|�dt|� � |d7 }�q�i g }}|D ]�\}}} ||v �r0�qd||<