Ë
    ¹ûàgq  ã                   ó\   — d Z ddlZ G d„ d«      Zdd„Z G d„ d«      Z G d„ d	e«      Zd
„ Zy)zJsLex: a lexer for JavaScripté    Nc                   ó   — e Zd ZdZdZdd„Zy)ÚTokz,
    A specification for a token class.
    r   Nc                 óŠ   — t         j                  | _        t         xj                  dz  c_        || _        || _        || _        y )Né   )r   ÚnumÚidÚnameÚregexÚnext)Úselfr	   r
   r   s       úP/var/www/skyplay_api_hub/venv/lib/python3.12/site-packages/django/utils/jslex.pyÚ__init__zTok.__init__   s/   € Ü—'‘'ˆŒÜ�Š�1‰�ØˆŒ	ØˆŒ
Øˆ�	ó    ©N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   © r   r   r   r      s   „ ñð €Côr   r   c                 óX   ‡‡— dj                  ˆˆfd„| j                  «       D «       «      S )z¤
    Create a regex from a space-separated list of literal `choices`.

    If provided, `prefix` and `suffix` will be attached to each choice
    individually.
    ú|c              3   óT   •K  — | ]  }‰t        j                  |«      z   ‰z   –— Œ! y ­wr   )ÚreÚescape)Ú.0ÚcÚprefixÚsuffixs     €€r   ú	<genexpr>zliterals.<locals>.<genexpr>   s#   øè ø€ ÒL°q�FœRŸY™Y q›\Ñ)¨FÕ2ÑLùs   ƒ%()ÚjoinÚsplit)Úchoicesr   r   s    ``r   Úliteralsr#      s    ù€ ð �8‰8ÔL¸G¿M¹M»OÔLÓLÐLr   c                   ó   — e Zd ZdZd„ Zd„ Zy)ÚLexerz2
    A generic multi-state regex-based lexer.
    c           	      ó’  — i | _         i | _        |j                  «       D ]Ÿ  \  }}g }|D ]B  }d|j                  z  }|| j                  |<   |j	                  d|›d|j
                  ›d�«       ŒD t        j                  dj                  |«      t        j                  t        j                  z  «      | j                   |<   Œ¡ || _        y )Nzt%dz(?P<ú>ú)r   )ÚregexesÚtoksÚitemsr   Úappendr
   r   Úcompiler    Ú	MULTILINEÚVERBOSEÚstate)r   ÚstatesÚfirstr0   ÚrulesÚpartsÚtokÚgroupids           r   r   zLexer.__init__%   sª   € ØˆŒØˆŒ	à"ŸL™L›Nò 	Y‰LˆE�5ØˆEØò B�Ø #§&¡&™.�Ø%(�—	‘	˜'Ñ"Ø—’ªW°c·i³iÐ@ÕAðBô #%§*¡*¨S¯X©X°e«_¼b¿l¹lÌRÏZÉZÑ>WÓ"XˆD�L‰L˜Òð	Yð ˆ�
r   c              #   ób  K  — t        |«      }| j                  }| j                  }| j                  }d}||k  rn||   j	                  ||«      D ]P  }|j
                  }||   }	||   }
|t        |
«      z  }|	j                  |
f–— |	j                  sŒD|	j                  } n ||k  rŒn|| _        y­w)zW
        Lexically analyze `text`.

        Yield pairs (`name`, `tokentext`).
        r   N)Úlenr0   r)   r*   ÚfinditerÚ	lastgroupr	   r   )r   ÚtextÚendr0   r)   r*   ÚstartÚmatchr	   r5   Útoktexts              r   Úlexz	Lexer.lex3   sµ   è ø€ ô �$‹iˆØ—
‘
ˆØ—,‘,ˆØ�y‰yˆØˆà�cŠkØ  ™×0Ñ0°°uÓ=ò 	�Ø—‘�Ø˜4‘j�Ø ™+�Øœ˜W›Ñ%�Ø—x‘x Ð)Ò)à—8“8ØŸH™H�EÙð	ð �c‹kð ˆ�
ùs   ‚BB/ÂB/Â'B/N)r   r   r   r   r   r@   r   r   r   r%   r%       s   „ ñòór   r%   c                   óÜ  ‡ — e Zd ZdZ edd«       edd«       edd«       ed ed	d
¬«      d¬«       ed edd
¬«      d¬«       eddd¬«       eddd¬«       edd«       eddd¬«       ed ed«      d¬«       ed ed«      d¬«       ed ed«      d¬«       eddd¬«       eddd¬«      gZ ed d!«      gZe ed ed"«      d¬«      gz   ez   e ed#d$d¬«      gz   ez   d%œZˆ fd&„Z	ˆ xZ
S )'ÚJsLexerzô
    A JavaScript lexer

    >>> lexer = JsLexer()
    >>> list(lexer.lex("a = 1"))
    [('id', 'a'), ('ws', ' '), ('punct', '='), ('ws', ' '), ('dnum', '1')]

    This doesn't properly handle non-ASCII characters in the JavaScript source.
    Úcommentz/\*(.|\n)*?\*/Úlinecommentz//.*?$Úwsz\s+Úkeywordal  
                           break case catch class const continue debugger
                           default delete do else enum export extends
                           finally for function if import in instanceof
                           new return super switch this throw try typeof
                           var void while with
                           z\b)r   Úreg)r   Úreservedznull true falseÚdivr   z™
                  ([a-zA-Z_$   ]|\\u[0-9a-fA-Z]{4})   # first char
                  ([a-zA-Z_$0-9]|\\u[0-9a-fA-F]{4})*  # rest chars
                  Úhnumz0[xX][0-9a-fA-F]+Úonumz0[0-7]+Údnuma|  
                    (   (0|[1-9][0-9]*)     # DecimalIntegerLiteral
                        \.                  # dot
                        [0-9]*              # DecimalDigits-opt
                        ([eE][-+]?[0-9]+)?  # ExponentPart-opt
                    |
                        \.                  # dot
                        [0-9]+              # DecimalDigits
                        ([eE][-+]?[0-9]+)?  # ExponentPart-opt
                    |
                        (0|[1-9][0-9]*)     # DecimalIntegerLiteral
                        ([eE][-+]?[0-9]+)?  # ExponentPart-opt
                    )
                    Úpunctz’
                         >>>= === !== >>> <<= >>= <= >= == != << >> &&
                         || += -= *= %= &= |= ^=
                         z	++ -- ) ]z){ } ( [ . ; , < > + - * % & | ^ ! ~ ? : =Ústringz"([^"\\]|(\\(.|\n)))*?"z'([^'\\]|(\\(.|\n)))*?'Úotherú.z/= /r
   aë  
                    /                       # opening slash
                    # First character is..
                    (   [^*\\/[]            # anything but * \ / or [
                    |   \\.                 # or an escape sequence
                    |   \[                  # or a class, which has
                            (   [^\]\\]     #   anything but \ or ]
                            |   \\.         #   or an escape sequence
                            )*              #   many times
                        \]
                    )
                    # Following characters are same, except for excluding a star
                    (   [^\\/[]             # anything but \ / or [
                    |   \\.                 # or an escape sequence
                    |   \[                  # or a class, which has
                            (   [^\]\\]     #   anything but \ or ]
                            |   \\.         #   or an escape sequence
                            )*              #   many times
                        \]
                    )*                      # many times
                    /                       # closing slash
                    [a-zA-Z0-9]*            # trailing flags
                )rI   rG   c                 ó:   •— t         ‰| �  | j                  d«       y )NrG   )Úsuperr   r1   )r   Ú	__class__s    €r   r   zJsLexer.__init__Ò   s   ø€ Ü‰Ñ˜Ÿ™ eÕ,r   )r   r   r   r   r   r#   Úboth_beforeÚ
both_afterr1   r   Ú__classcell__)rS   s   @r   rB   rB   N   s‰  ø„ ññ0 	ˆIÐ(Ó)ÙˆM˜9Ó%ÙˆD�&ÓÙØÙðð ô	ð ô	
ñ 	ˆJ™Ð!2¸5ÔAÈÔNÙØðð ô	
ñ 	ˆFÐ(¨uÔ5ÙˆF�JÓÙØðð ô!	
ñ$ 	ØÙðóð ô		
ñ 	ˆG‘X˜kÓ*°Ô7ÙˆG‘XÐIÓJÐQVÔWÙˆHÐ0°uÔ=ÙˆHÐ0°uÔ=ðy=€Kñ@ 	ˆG�TÓð€Jð á�™ &Ó)°Ô6ð
ñ
ð ñ	ð áØðð. ô3ð
ñ
ð< ñ=ñ'€F÷R-ð -r   rB   c                 óF  — d„ }t        «       }g }|j                  | «      D ]n  \  }}|dk(  rd}nP|dk(  r4|j                  d«      r:t        j                  d||dd «      }d	|z   d	z   }n|d
k(  r|j                  dd«      }|j                  |«       Œp dj                  |«      S )z³
    Convert the JavaScript source `js` into something resembling C for
    xgettext.

    What actually happens is that all the regex literals are replaced with
    "REGEX".
    c                 ó   — | d   }|dk(  ry|S )z1Used in a regex to properly escape double quotes.r   ú"z\"r   )ÚmÚss     r   Úescape_quotesz-prepare_js_for_gettext.<locals>.escape_quotesß   s   € àˆa‰DˆØ�Š8ØàˆHr   r
   z"REGEX"rN   ú'z\\.|.r   éÿÿÿÿrY   r   ú\ÚUÚ )rB   r@   Ú
startswithr   ÚsubÚreplacer,   r    )Újsr\   Úlexerr   r	   r5   Úgutss          r   Úprepare_js_for_gettextrh   Ö   s®   € òô ‹I€EØ
€AØ—Y‘Y˜r“]ò ‰	ˆˆcØ�7Š?ð ‰CØ�XÒð �~‰~˜cÔ"Ü—v‘v˜h¨°s¸1¸R°yÓA�Ø˜D‘j 3Ñ&‘Ø�TŠ\ð —+‘+˜d CÓ(ˆCØ	�‰��ð!ð" �7‰7�1‹:Ðr   )ra   ra   )r   r   r   r#   r%   rB   rh   r   r   r   ú<module>ri      s<   ðÙ #ó 
÷ñ óM÷+ñ +ô\E-ˆeô E-óP$r   