
    Mh                     x    d Z ddlZddlmZmZmZmZ ddlmZm	Z	m
Z
mZmZmZmZmZmZ dgZ G d de          ZdS )z
    pygments.lexers.nimrod
    ~~~~~~~~~~~~~~~~~~~~~~

    Lexer for the Nim language (formerly known as Nimrod).

    :copyright: Copyright 2006-2025 by the Pygments team, see AUTHORS.
    :license: BSD, see LICENSE for details.
    N)
RegexLexerincludedefaultbygroups)	TextCommentOperatorKeywordNameStringNumberPunctuationErrorNimrodLexerc                      e Zd ZdZdZdZddgZddgZdgZd	Z	e
j        e
j        z  Zd
 Zg dZg dZg dZg dZdej        dfdej        fdej        dfdefdej        dfdefdefd eej        eej                  dfdedfdej        dfded fd!ej        d"fd# ee           d$ej         fd% eeej                  d&fd# ee           d$efd'!                     eg d(                    ej"        fd)ej#        fd# ee           d$e$j%        fd# ee           d$ej&        fd*e$fd+e'j(        d,fd-e'j)        d.fd/e'j*        d.fd0e'j+        d.fd1e'j,        d.fd2ej        fd3e-fgd4ej.        fd!ej        d5fd6ej        fgd7ej/        fd8efd9efd:efgd;ej        fdej        d<fd=ej        d5fd>ej        fgd;ej        fdej        d<fd?ej        d5fd>ej        fgd@ej.        fded5f e0dA          gdBed5fdCej.        f e0dA          gdej        d5f e0dA          dDej        fgdEe$j1        d5fdFe$j1        d5fgdDefgdGe'j(        fdHe'j(        f e2d5          gdIe'j(        f e2d5          gdJe'j,        j3        fdKe'j,        f e2d5          gdLefdMej        fdNed5fdOe$j4        fgdPefdMej        fdQej        d5fdRej        fgdSZ5dTS )Ur   z
    For Nim source code.
    Nimrodzhttp://nim-lang.org/nimrodnimz*.nimz*.nimrodz
text/x-nimz1.5c                     g }g }| D ][}|D ],}|                     |           |                     d           -|                     d                    |                     g }\d                    |          S )Nz_? |)appendjoin)wordsnewWordsnewwordchs        V/var/www/html/test/jupyter/venv/lib/python3.11/site-packages/pygments/lexers/nimrod.pyunderscorizezNimrodLexer.underscorize"   s     	 	D ! !

2

4    OOBGGCLL)))CCxx!!!    )8addrandasasmbindblockbreakcasecastconceptconstcontinue	converterdeferdiscarddistinctdivdoelifelseendenumexceptexportfinallyforifinyield	interfaceisisnotiteratorletmixinmodnotnotinobjectoforoutptrraiserefreturnshlshrstatictrytupletypeusingwhenwhilexor)niltruefalse)r#   rJ   rF   rY   rP   rQ   r2   rE   r=   rG   r@   rA   )intint8int16int32int64floatfloat32float64boolcharrangearrayseqsetstringz##\[
doccommentz##.*$z#\[commentz#.*$z\{\.pragmaz[*=><+\-/@$~&%!?|\\\[\]]z<\.\.|\.|,|\[\.|\.\]|\{\.|\.\}|\(\.|\.\)|\{|\}|\(|\)|:|\^|`|;z(\n\s*)(of)(\s)
casebranchz
(?:[\w]+)"rdqsz"""tdqs"dqs'chars(z)\bz0(proc|func|method|macro|template)(\s)(?![(\[\]])funcnamez({})\b)fromimportr   r9   z(v_?a_?r)\bz&\b((?![_\d])\w)(((?!_)\w)|(_(?!_)\w))*z![0-9][0-9_]*(?=([e.]|\'f(32|64))))float-suffixfloat-numberz0x[a-f0-9][a-f0-9_]*
int-suffixz0b[01][01_]*z0o[0-7][0-7_]*z[0-9][0-9_]*z\s+z.+$z-\\([\\abcefnrtvl"\']|x[a-f0-9]{2}|[0-9]{1,3})z#pop.z(?<!\$)\$(\d+|#|\w+)+z[^\\\'"$\n]+z[\'"\\]z\$z[^\]#]+z#pushz\]##z[\]#]z\]#z0\\([\\abcefnrtvl"\']|\n|x[a-f0-9]{2}|[0-9]{1,3})stringsz"(?!")z""z\nz$((?![\d_])\w)(((?!_)\w)|(_(?!_)\w))*z`.+`z\.(?!\.)[0-9_]*[f]*ze[+-]?[0-9][0-9_]*z
\'f(32|64)z
\'i(32|64)z	\'i(8|16),z[\n ]+:z\w+|[^:]z[:,]z\.\}z\w+|\W+|[^.}])rootru   r~   rl   rm   rs   rp   rq   rw   nlr{   rz   r|   ro   rn   N)6__name__
__module____qualname____doc__nameurlaliases	filenames	mimetypesversion_addedre	MULTILINE
IGNORECASEflagsr    keywordskeywordsPseudoopWordstypesr   Docr   	MultilineOtherr	   r   r   r   
Whitespacer
   DoubleCharWordformat	NamespaceDeclarationr   BuiltinPseudor   FloatHexBinOctIntegerr   EscapeInterpolr   Functionr   LongLabeltokens r!   r   r   r      s         D
 CG*%IIML2=(E	" 	" 	"	 	 	H  N  G
  E fj,/vz"W&	2g flH- )(3L  $/7*./"; ";<HJ FF+V]F+&%  &+w' -,,w'',,,hm<@Xgt//=-,,x((---w7ll+R+R+RSSTT W01*,,u%%***DL93,,~..333W^D 7= 2\;=$fj,?fj,7
L9fnl; T_%UOg4
l >v}M6;'6;
 &v7f% FO
 $fj'*fj&)vz"	
 *+W&0W&/w()	
 A]66"GI	
 'FM"GI
 V]F+GIFM"
 5dmVLdmV,

 FO
 $V\2"FL1GFOO
 FL)GFOO

 FN/06>*GFOO
 ;(8V$$*%	
 dO(flF+v|,	
wA AFFFr!   )r   r   pygments.lexerr   r   r   r   pygments.tokenr   r   r	   r
   r   r   r   r   r   __all__r   r   r!   r   <module>r      s     
			 A A A A A A A A A A A A                      /s s s s s* s s s s sr!   