ok

Mini Shell

Direktori : /usr/lib/python2.7/site-packages/babel/messages/
Upload File :
Current File : //usr/lib/python2.7/site-packages/babel/messages/jslexer.pyo

�
��Mc+@sdZddlZddlmZdddddd	d
ddd
ddddddddddddddddddd d!d"d#d$d%d&d'd(d)d*d+d,d-d.g+Zejd/��id0d16d2d36d4d56d6d76d8d96Zdejd:�fdejd;�fd<ejd=�fd>ejd?�fd@ejdA�fdBejdC�fdDejdEdj	e
eje���fdFejdG�fgZejdH�Z
ejdI�ZejdJ�ZejdKej�ZejdL�ZdMefdN��YZdO�ZdP�ZdQ�ZdS(RsJA simple JavaScript 1.5 lexer which is used for the JavaScript
extractor.
i����N(t
itemgettert+t-t*t%s!=s==t<t>s<=s>=t=s+=s-=s*=s%=s<<s>>s>>>s<<=s>>=s>>>=t&s&=t|s|=s&&s||t^s^=t(t)t[t]t{t}t!s--s++t~t,t;t.t:cCstt|�t|��S(N(tcmptlen(tatb((s:/usr/lib/python2.7/site-packages/babel/messages/jslexer.pyt<lambda>ssRstfs
tns
trs	tts\s+(?u)s<!--.*tlinecomments//.*tmultilinecomments/\*.*?\*/(?us)tnames(\$+\w*|[^\W\d]\w*)(?u)tnumbersf(?x)(
        (?:0|[1-9]\d*)
        (\.\d+)?
        ([eE][-+]?\d+)? |
        (0x[a-fA-F0-9]+)
    )toperators(%s)tstringsY(?xs)(
        '(?:[^'\\]*(?:\\.[^'\\]*)*)'  |
        "(?:[^"\\]*(?:\\.[^"\\]*)*)"
    )s/=?s)/(?:[^/\\]*(?:\\.[^/\\]*)*)/[a-zA-Z]*(?s)s(\r\n|\n|\r)s\\s[a-fA-F0-9]{1,4}tTokencBsSeZdZdZd�Zeed��Zeed��Zeed��Z	RS(s-Represents a token as returned by `tokenize`.cCstj||||f�S(N(ttuplet__new__(tclsttypetvaluetlineno((s:/usr/lib/python2.7/site-packages/babel/messages/jslexer.pyR(?siii((
t__name__t
__module__t__doc__t	__slots__R(tpropertyRR*R+R,(((s:/usr/lib/python2.7/site-packages/babel/messages/jslexer.pyR&;s	cCs)|jdkr|jdkS|jdkS(
szA helper function that helps the tokenizer to decide if the current
    token may be followed by a division operator.
    R$RRRs++s--R"R#R%tregexp(RRRs++s--(snameR#sstringR2(R*R+(ttoken((s:/usr/lib/python2.7/site-packages/babel/messages/jslexer.pytindicates_divisionGs
cCs�tjd|dd!�}g}|j}d}x/|jd|�}|dkrSPn||||!�||d}|tkr�|t|�n�|dkrItj||d�}|dk	r<|j�}t	|�dkry|t
t|d	���Wntk
rqX|d
}q1n|||�|j
�}q1qS||�n
||�|d}q1|t	|�kr�|||�ndj|�S(
s�Unquote a string with JavaScript rules.  The string has to start with
    string delimiters (``'`` or ``"``.)

    :return: a string
    s\1ii����is\tuUiiiiuN(tline_join_retsubtappendtfindtescapest
uni_escape_retmatchtNonetgroupRtunichrtintt
ValueErrortendtjoin(R%tresulttaddtpost
escape_post	next_chartescapedt
escaped_value((s:/usr/lib/python2.7/site-packages/babel/messages/jslexer.pytunquote_stringPs@	




c
cs&t}d}d}t|�}x||kr!x�tD].\}}|j||�}|dk	r4Pq4q4W|r�tj||�}d}ntj||�}d}|dkr�|d7}q!n|j�}|dk	r�t|||�}	t	|	�}|	Vn|tt
j|��7}|j�}q!WdS(sGTokenize a JavaScript source.

    :return: generator of `Token`\s
    iiR$R2N(
tFalseRtrulesR<R=tdivision_retregex_reR>R&R4tline_retfindallRB(
tsourcet
may_divideRFR,RBt
token_typetruleR<ttoken_valueR3((s:/usr/lib/python2.7/site-packages/babel/messages/jslexer.pyttokenize�s0	
(R/tret
babel.utilRt	operatorstsortR:R=tcompileRCtmaptescapeRMRNRORPtpatternR6R;R'R&R4RKRW(((s:/usr/lib/python2.7/site-packages/babel/messages/jslexer.pyt<module>s6!!*)		+				:

Zerion Mini Shell 1.0