o a(@sdZddlmZmZmZmZddlmZmZm Z m Z m Z m Z m Z mZmZmZgdZGdddeZGdddeZGd d d eZGd d d eZGd ddeZGdddeZdS)z pygments.lexers.esoteric ~~~~~~~~~~~~~~~~~~~~~~~~ Lexers for esoteric languages. :copyright: Copyright 2006-2021 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. ) RegexLexerincludewordsbygroups) TextCommentOperatorKeywordNameStringNumber PunctuationError Whitespace)BrainfuckLexer BefungeLexer RedcodeLexer CAmkESLexer CapDLLexer AheuiLexerc@seZdZdZdZddgZddgZdgZdej fd ej fd ej fd e fgd e d fdefedgd e dfde dfedgdZddZdS)rze Lexer for the esoteric `BrainFuck `_ language. Brainfuck brainfuckbfz*.bfz*.bzapplication/x-brainfuckz[.,]+z[+-]+z[<>]+z[^.,+\-<>\[\]]+z\[loopz\]commonz#pushz#pop)rrootrcCsd}d}tdt|}|d|D]}|dks|dkr|d7}|dks'|dkr+|d7}q|d |kr4d S|d |kr is brainfuck.rN+-<>g?g?z[-]g?)maxlen)textplus_minus_countgreater_less_countrange_to_checkcresultr*:/usr/lib/python3/dist-packages/pygments/lexers/esoteric.py analyse_text2s"  zBrainfuckLexer.analyse_textN)__name__ __module__ __qualname____doc__namealiases filenames mimetypesr TagBuiltinVariablerr rrtokensr,r*r*r*r+rs* rc@seZdZdZdZdgZdgZdgZddefde fd e j fd e j fd e fd e jfd ejfdejfdefde fdefdefg iZdS)rz{ Lexer for the esoteric `Befunge `_ language. .. versionadded:: 0.7 Befungebefungez *.befungezapplication/x-befungerz[0-9a-f]z [+*/%!`-]z[<>^v?\[\]rxjk]z [:\\$.,n]z[|_mw]z[{}]z".*?"z\'.z[#;]z [pg&~=@iotsy]z[()A-Z]\s+N)r-r.r/r0r1r2r3r4r rr r7r6r r5r DoubleSinglerrr8r*r*r*r+rLs*rc@seZdZdZdZddgZddgZddeee j efd efd e fd e fd e fd e fe dddefe dddejfdejfe dddejfdee j ee j fdee j ee j fdejfdefdejfdefdejfdefgiZdS)rz Basic lexer for the input language for the `CAmkES `_ component platform. .. versionadded:: 2.1 CAmkEScamkesidl4z*.camkesz*.idl4r^(\s*)(#.*)(\n)r;/\*(.|\n)*?\*/z//.*$z [\[(){},.;\]]z[~!%^&*+=|?:<>/-])"assembly attribute component composition configuration connection connectorconsumescontroldataportDataport DataportsemitseventEventEventsexportfromgrouphardwarehas interface Interfacemaybe procedure Procedure Proceduresprovidestemplatethreadthreadstouseswith\bsuffix)boolbooleanBufchar characterdoublefloatininoutintint16_6int32_tint64_tint8_tintegermutexoutrealrefin semaphoresignedstringstructuint16_tuint32_tuint64_tuint8_t uintptr_tunsignedvoidz%[a-zA-Z_]\w*_(priority|domain|buffer))dma_pool from_access to_accessz#(import)(\s+)((?:<[^>]*>|"[^"]*");)z$(include)(\s+)((?:<[^>]*>|"[^"]*");)0[xX][\da-fA-F]+z-?[\d]+z-?[\d]+\.[\d]+z"[^"]*"z[Tt]rue|[Ff]alsez [a-zA-Z_]\w*N)r-r.r/r0r1r2r3rrrPreprocr rrr TypeReservedr HexFloatr r r6r8r*r*r*r+rjsT   rc@seZdZdZdZdgZdgZddeee j efdefde fd e fd e fd e fe d d de fe dd de jfe dd de jfdejfdefe dd defe dd defdefgiZdS)ra= Basic lexer for `CapDL `_. The source of the primary tool that reads such specifications is available at https://github.com/seL4/capdl/tree/master/capDL-tool. Note that this lexer only supports a subset of the grammar. For example, identifiers can shadow type names, but these instances are currently incorrectly highlighted as types. Supporting this would need a stateful lexer that is considered unnecessarily complex for now. .. versionadded:: 2.2 CapDLcapdlz*.cdlrrAr;rBz (//|--).*$z[<>\[(){},:;=\]]z\.\.)archarm11capschild_ofia32irqmapsobjectsrerf)aep asid_poolcnodeepframe io_deviceio_portsio_pt notificationpdpttcbutvcpu)asidaddrbadgecacheddomdomainIDelffault_epGguard guard_sizeinitippriospRRGRXRWRWGRWXWWGWXlevelmasked master_replypaddrportsreplyuncachedrz\d+(\.\d+)?(k|M)?)bits)cspacevspace reply_slot caller_slotipc_buffer_slotz[a-zA-Z_][-@\.\w]*N)r-r.r/r0r1r2r3rrrrr rr rrr rr r8r*r*r*r+rsP  rc @seZdZdZdZdgZdgZdZdZdde fd e j fd d ee jfd d ee jfd e fd efdefdefdejfg iZdS)rz A simple Redcode lexer based on ICWS'94. Contributed by Adam Blinkinsop . .. versionadded:: 0.8 Redcoderedcodez*.cw)DATMOVADDSUBMULDIVMODJMPJMZJMNDJNCMPSLTSPLORGEQUEND)ABABBAFXIrr;z;.*$z\b(%s)\b|z [A-Za-z_]\w+z[-+*/%]z[#$@<>]z[.,]z[-+]?\d+N)r-r.r/r0r1r2r3opcodes modifiersrrr=joinr Function Decoratorrr r Integerr8r*r*r*r+rs&rc@s4eZdZdZdZdgZdgZddefdefgiZ dS) rz| Aheui_ Lexer. Aheui_ is esoteric language based on Korean alphabets. .. _Aheui: http://aheui.github.io/ Aheuiaheuiz*.aheuiru[나-낳냐-냫너-넣녀-녛노-놓뇨-눟뉴-닇다-닿댜-댷더-덯뎌-뎧도-돟됴-둫듀-딓따-땋땨-떃떠-떻뗘-뗳또-똫뚀-뚷뜌-띟라-랗랴-럏러-렇려-렿로-롷료-뤃류-릫마-맣먀-먛머-멓며-몋모-뫃묘-뭏뮤-믷바-밯뱌-뱧버-벟벼-볗보-봏뵤-붛뷰-빃빠-빻뺘-뺳뻐-뻫뼈-뼣뽀-뽛뾰-뿧쀼-삏사-샇샤-샿서-섷셔-셯소-솧쇼-숳슈-싛싸-쌓쌰-썋써-쎃쎠-쎻쏘-쏳쑈-쑿쓔-씧자-잫쟈-쟣저-젛져-졓조-좋죠-줗쥬-즿차-챃챠-챻처-첳쳐-쳫초-촣쵸-춯츄-칗카-캏캬-컇커-컿켜-켷코-콯쿄-쿻큐-킣타-탛탸-턓터-텋텨-톃토-톻툐-퉇튜-틯파-팧퍄-퍟퍼-펗펴-폏포-퐇표-풓퓨-픻하-핳햐-햫허-헣혀-혛호-홓효-훟휴-힇].N) r-r.r/r0r1r2r3rrr8r*r*r*r+rs rN)r0pygments.lexerrrrrpygments.tokenrrrr r r r r rr__all__rrrrrrr*r*r*r+s 09D<$