Website : rimsha.abasa.com
backdoor
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
proc
/
self
/
root
/
lib
/
python3
/
dist-packages
/
pygments
/
__pycache__
/
Filename :
regexopt.cpython-310.pyc
back
Copy
o ���a � @ sl d Z ddlZddlmZ ddlmZ ddlmZ ddlmZ e� d�Z ed�Zdd � Zd d� Z dd d�ZdS )a pygments.regexopt ~~~~~~~~~~~~~~~~~ An algorithm that generates optimized regexes for matching long lists of literal strings. :copyright: Copyright 2006-2021 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. � N)�escape)�commonprefix)�groupby)� itemgetterz[\[\^\\\-\]]c C s dt �dd� d�| �� d S )N�[c S s d| � � S )N�\)�group)�m� r �3/usr/lib/python3/dist-packages/pygments/regexopt.py�<lambda> s zmake_charset.<locals>.<lambda>� �])� CS_ESCAPE�sub�join)�lettersr r r �make_charset s r c s� |rdpd}| s dS | d � t | �dkr|t� � | S � s-|t| dd� d� d | S t � �dkrlg }g }| D ]}t |�dkrG|�|� q9|�|� q9t |�dkrl|rd|t|d� d t|� | S |t|� | S t| �}|r�t |��|t|� t�fd d �| D �d� | S dd � | D �}t|�}|r�t |��|tt�fdd �| D ��d� t|ddd� � | S |d�dd � t| � fdd��D �� | S )zEReturn a regex that matches any string in the sorted list of strings.�)r r � Nz(?:�?�|c s g | ]}|� d � �qS �Nr ��.0�s)�plenr r � <listcomp>? s z#regex_opt_inner.<locals>.<listcomp>c S s g | ] }|d d d� �qS )N���r r r r r r B s c 3 s � | ] }|d � � V qd S r r r )�slenr r � <genexpr>H s � z"regex_opt_inner.<locals>.<genexpr>r c s s"