3

V'ícŒ(ã@sšdZddlZddlmZmZmZmZmZmZddl	m
Z
mZmZm
Z
mZmZmZmZmZmZdddgZGdd„deƒZGd	d„deƒZGd
d„deƒZdS)zÍ
    pygments.lexers.dylan
    ~~~~~~~~~~~~~~~~~~~~~

    Lexers for the Dylan language.

    :copyright: Copyright 2006-2022 by the Pygments team, see AUTHORS.
    :license: BSD, see LICENSE for details.
éN)ÚLexerÚ
RegexLexerÚbygroupsÚ
do_insertionsÚdefaultÚline_re)
ÚCommentÚOperatorÚKeywordÚNameÚStringÚNumberÚPunctuationÚGenericÚLiteralÚ
WhitespaceÚ
DylanLexerÚDylanConsoleLexerÚ
DylanLidLexercž@seZdZdZdZdZdgZdddgZdgZe	j
Zd	d
ddd
ddddddddddddddddddd d!d"d#d$d%d&d'd(d)d*d+d,d-h%Zd.d/d0d1d2d3d4d5d6d7d8d9d:d;d<d=d>d?d@dAdBdCdDdEdFdGdHdIdJdKdLhZ
dMdNdOdPdQdRdSdTdUdVdWdXdYdZd[dQhZd\d]d^d_d`dadbdcdddedfdgdhdidjdkdldmdndodpdqdrdsdtdudvdwdxdydzd{d|d}d~dd€dd‚dƒd„d…d†d‡dˆd‰dŠd‹dŒddŽddd‘d’d“d”d•d–d—d˜d™dšd›dœddždŸd d¡d¢d£d¤d¥d¦d§d¨d©dªd«d¬d­d®d¯d°d±d²d³d´dµd¶d·d¸d¹dºd»d¼d½d¾d¿dÀdÁdÂdÃdÄdÅdÆdÇdÈdÉdÊdËdÌdÍdÎdÏdÐdÑdÒdÓdÔdÕdÖd×dØdÙdÚdÛdÜdÝdÞdßdàdEd)dádâdãdädådædçdèdédêdëdìdídîdïdðdñdòdódôdõdöd÷hžZdøZdùdú„Zdûefdüejfdýeejeeeƒfedþƒgdûefdÿeejeƒfdejdfdedfdejfdejfdejfdej fdej!fd	ej"fd
edeej#eej$ƒfdeej#eej$ƒfd
eej#fde%fdefde&fdej'dfde(fede(fdWedYej)fdedej*j+fdeej,feefgdejfdejdfdejdfdejfgdej'dfdej'fgdedfdej-fdefdefdefgd œZ.d!S("rz<
    For the Dylan language.

    .. versionadded:: 0.7
    ZDylanzhttp://www.opendylan.org/Zdylanz*.dylanz*.dylz*.intrztext/x-dylanÚsubclassZabstractÚblockZconcreteZconstantÚclassz
compiler-openzcompiler-sidewaysÚdomainZdynamicz
each-subclassÚ	exceptionÚexcludeÚfunctionZgenericÚhandlerZ	inheritedÚinlinezinline-onlyÚinstanceZ	interfaceÚimportÚkeywordZlibraryÚmacroÚmethodÚmoduleÚopenZprimaryÚrequiredZsealedZsidewaysZ	singletonZslotÚthreadÚvariableZvirtualZaboveZ
afterwardsÚbeginZbelowZbyZcaseÚcleanupÚcreateZdefineÚelseZelseifÚendÚexportÚfinallyÚforÚfromÚifÚinZletÚlocalZ	otherwiseÚrenameÚselectÚsignalZthenZtoZunlessZuntilZuseÚwhenÚwhileú~ú+ú-Ú*ú|ú^ú=z==z~=z~==ú<z<=ú>z>=ú&ÚabortÚabsÚaddzadd!z
add-methodzadd-newzadd-new!zall-superclassesÚalwayszany?zapplicable-method?ÚapplyZarefzaref-setterÚaszas-lowercasez
as-lowercase!zas-uppercasez
as-uppercase!Zashzbackward-iteration-protocolÚbreakZceilingzceiling/Zcerrorz
check-typeÚchoosez	choose-byZ
complementZcomposeZconcatenatezconcatenate-aszcondition-format-argumentszcondition-format-stringZconjoinz
copy-sequenceZcurryzdefault-handlerZ	dimensionZ
dimensionszdirect-subclasseszdirect-superclassesZdisjoinZdozdo-handlersÚelementzelement-setterzempty?Úerrorzeven?zevery?zfalse-orzfill!zfind-keyzfind-methodÚfirstzfirst-setterÚfloorzfloor/zforward-iteration-protocolzfunction-argumentszfunction-return-valueszfunction-specializersÚgcdz#generic-function-mandatory-keywordszgeneric-function-methodsÚheadzhead-setterÚidentityZ
initializez	instance?z	integral?Úintersectionzkey-sequencezkey-testÚlastzlast-setterZlcmZlimitedÚlistZlogandzlogbit?ZlogiorZlognotZlogxorÚmakeÚmapzmap-aszmap-intoÚmaxzmember?zmerge-hash-codesÚminZmoduloÚnegativez	negative?znext-methodzobject-classzobject-hashzodd?zone-ofÚpairÚpopzpop-lastz	positive?Úpushz	push-lastÚrangeZrankZrcurryÚreduceZreduce1Ú	remainderÚremovezremove!zremove-duplicateszremove-duplicates!zremove-key!z
remove-methodzreplace-elements!zreplace-subsequence!z
restart-queryzreturn-allowed?zreturn-descriptionzreturn-queryÚreversezreverse!Úroundzround/zrow-major-indexÚsecondz
second-setterzshallow-copyÚsizezsize-setterzslot-initialized?Úsortzsort!zsorted-applicable-methodszsubsequence-positionzsubtype?ztable-protocolÚtailztail-setterZthirdzthird-setterÚtruncatez	truncate/ztype-error-expected-typeztype-error-valuez
type-for-copyz
type-unionÚunionÚvaluesZvectorzzero?z\\?[\w!&*<>|^$%@\-+~?/=]+ccs xštj||ƒD]Š\}}}|tkrŒ|jƒ}||jkrB|tj|fVq||jkrZ|t|fVq||jkrt|tj|fVq||j	krŒ|t
|fVq|||fVqWdS)N)rÚget_tokens_unprocessedrÚlowerÚbuiltinsÚBuiltinÚkeywordsr
Ú	functionsÚ	operatorsr	)ÚselfÚtextÚindexÚtokenÚvalueZlowercase_value©rvú9/tmp/pip-build-gk9425m9/Pygments/pygments/lexers/dylan.pyrj^s 



z!DylanLexer.get_tokens_unprocessedz\s+z//.*?\nz)([a-z0-9-]+)(:)([ \t]*)(.*(?:\n[ \t].+)*)Úcodez(//.*?)(\n)z/\*Úcommentú"Ústringz/'(\\.|\\[0-7]{1,3}|\\x[a-f0-9]{1,2}|[^\\\'\n])'z#b[01]+z#o[0-7]+z0[-+]?(\d*\.\d+(e[-+]?\d+)?|\d+(\.\d*)?e[-+]?\d+)z[-+]?\d+z#x[0-9a-f]+z(\?z6)(:)(token|name|variable|expression|body|case-body|\*)z9(\?)(:)(token|name|variable|expression|body|case-body|\*)z\?z,(=>|::|#\(|#\[|##|\?\?|\?=|\?|[(){}\[\],.;])z:=z#[tf]z#"z#[a-z0-9-]+ú:z\*z\$z[^*/]+z#pushz\*/z#popz[*/]z[^\\"]+z,\\([\\abfnrtv"\']|x[a-f0-9]{2,4}|[0-7]{1,3})z	[^\\"\n]+z\\\nz\\)Úrootrxryr r{N)/Ú__name__Ú
__module__Ú__qualname__Ú__doc__ÚnameÚurlÚaliasesÚ	filenamesÚ	mimetypesÚreÚ
IGNORECASEÚflagsrlrnrproZ
valid_namerjrrÚSinglerrÚ	Attributer	rrZ	MultilineZCharr
ZBinÚOctZFloatZIntegerZHexZTagrmrrZSymbolr
ZClassÚVariableÚGlobalÚConstantZEscapeÚtokensrvrvrvrwrsÄ



















c	@s^eZdZdZdZddgZddgZdgZej	Z
dd	efd
ee
jeƒfdeejeeeƒfgiZdS)
rzZ
    For Dylan LID (Library Interchange Definition) files.

    .. versionadded:: 1.6
    ZDylanLIDz	dylan-lidZlidz*.lidz*.hdpztext/x-dylan-lidr}z\s+z(//.*?)(\n)z"(.*?)(:)([ \t]*)(.*(?:\n[ \t].+)*)N)r~rr€rr‚r„r…r†r‡rˆr‰rrrrŠrr‹r	rrrvrvrvrwrÖsc@s:eZdZdZdZddgZdgZdgZej	dƒZ
dd	„Zd
S)rzä
    For Dylan interactive console output like:

    .. sourcecode:: dylan-console

        ? let a = 1;
        => 1
        ? a
        => 1

    This is based on a copy of the RubyConsoleLexer.

    .. versionadded:: 1.6
    z
Dylan sessionz
dylan-consolez
dylan-replz*.dylan-consoleztext/x-dylan-consolez\?| c	csÔtf|jŽ}d}g}x tj|ƒD]’}|jƒ}|jj|ƒ}|dk	r~|jƒ}|jt	|ƒdt
j|d|…fgfƒ|||d…7}q |r t||j
|ƒƒEdHd}g}|jƒt
j|fVq W|rÐt||j
|ƒƒEdHdS)NÚr)rÚoptionsrÚfinditerÚgroupÚ
_prompt_reÚmatchr,ÚappendÚlenrZPromptrrjÚstartZOutput)	rqrrZdylexerZcurcodeZ
insertionsr–ÚlineÚmr,rvrvrwrj	s(
z(DylanConsoleLexer.get_tokens_unprocessedN)r~rr€rr‚r„r…r†r‡Úcompiler•rjrvrvrvrwrós
)rr‡Zpygments.lexerrrrrrrZpygments.tokenrr	r
rrr
rrrrÚ__all__rrrrvrvrvrwÚ<module>	s 0
B