o
    xi<^                     @   s  d Z ddlZddlmZmZ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 ddlmZmZ ddlmZ g dZG dd	 d	eZG d
d deZG dd deZG dd deZG dd deZG dd deZG dd deZG dd deZG dd deZ dS )z
    pygments.lexers.c_like
    ~~~~~~~~~~~~~~~~~~~~~~

    Lexers for other C-like languages.

    :copyright: Copyright 2006-2017 by the Pygments team, see AUTHORS.
    :license: BSD, see LICENSE for details.
    N)
RegexLexerincludebygroupsinheritwordsdefault)TextCommentOperatorKeywordNameStringNumberPunctuation)CLexerCppLexer)_mql_builtins)		PikeLexer	NesCLexer	ClayLexerECLexer	ValaLexer	CudaLexer	SwigLexerMqlLexerArduinoLexerc                   @   sp   e Zd ZdZdZdgZddgZdgZeddd	e	fd
e	j
fdee	edfdefegdejdfdedfgdZdS )r   z[
    For `Pike <http://pike.lysator.liu.se/>`_ source code.

    .. versionadded:: 2.0
    Pikepikez*.pikez*.pmodztext/x-pike)=catchnewprivate	protectedpublicgaugethrowthrowsclass	interface	implementabstractextendsfromthissuperconstantfinalstaticimportuseexterninlineprotobreakcontinueifelseforwhiledoswitchcaseasinversionreturntruefalsenull__VERSION__	__MAJOR__	__MINOR__	__BUILD____REAL_VERSION____REAL_MAJOR____REAL_MINOR____REAL_BUILD____DATE____TIME____FILE____DIR____LINE____AUTO_BIGNUM____NT____PIKE____amigaos___Pragmastatic_assertdefinedsscanf\bsuffixz(bool|int|long|float|short|double|char|string|object|void|mapping|array|multiset|program|function|lambda|mixed|[a-z_][a-z0-9_]*_t)\b(class)(\s+)	classnamez[~!%^&*+=|?:<>/@-][a-zA-Z_]\w*#pop\s*(?=>)
statementsr_   N)__name__
__module____qualname____doc__namealiases	filenames	mimetypesr   r   Typer   r   r
   r   r   Classtokens rp   rp   W/home/ubuntu/.local/lib/python3.10/site-packages/wandb/vendor/pygments/lexers/c_like.pyr      s,    	


r   c                   @   sN   e Zd ZdZdZdgZdgZdgZdeddd	e	fed
dd	e	j
fegiZdS )r   z
    For `nesC <https://github.com/tinyos/nesc>`_ source code with preprocessor
    directives.

    .. versionadded:: 2.0
    nesCnescz*.ncztext/x-nescsrcrd   )r)   r?   asyncatomiccallcommand	component
componentsconfigurationeventr*   genericimplementationincludesr'   moduler   noracepostprovidessignaltaskusesr[   r\   )
	nx_structnx_union	nx_int8_t
nx_int16_t
nx_int32_t
nx_int64_t
nx_uint8_tnx_uint16_tnx_uint32_tnx_uint64_tN)re   rf   rg   rh   ri   rj   rk   rl   r   r   rm   r   ro   rp   rp   rp   rq   r   B   s(    r   c                   @   s   e Zd ZdZdZdgZdgZdgZdefde	j
fde	jfd	efd
efdefdejfdejfdejfdefdedfdedfgdejfdefgdefgdedfedgdedfededgdZdS )r   zT
    For `Clay <http://claylabs.com/clay/>`_ source.

    .. versionadded:: 2.0
    Clayz*.clayclayztext/x-clayz\sz//.*?$/(\\\n)?[*](.|\n)*?[*](\\\n)?/aK  \b(public|private|import|as|record|variant|instance|define|overload|default|external|alias|rvalue|ref|forward|inline|noinline|forceinline|enum|var|and|or|not|if|else|goto|return|while|switch|case|break|continue|for|in|true|false|try|catch|throw|finally|onerror|staticassert|eval|when|newtype|__FILE__|__LINE__|__COLUMN__|__ARG__)\bz[~!%^&*+=|:<>/-]z[#(){}\[\],;.]z0x[0-9a-fA-F]+[LlUu]*z
\d+[LlUu]*z\b(true|false)\bz(?i)[a-z_?][\w?]*z"""tdqs"dqsz(?i)\\(x[0-9a-f]{2}|.).\nra   stringsnl)rootr   r   r   r   N)re   rf   rg   rh   ri   rk   rj   rl   r   r	   
Singleline	Multiliner   r
   r   r   HexIntegerr   Builtinr   Escaper   ro   rp   rp   rp   rq   r   _   sD    
r   c                   @   s|   e Zd ZdZdZdgZddgZddgZedd	d
e	fedd	d
e	j
fdee	edfdejfegdejdfdedfgdZdS )r   zU
    For eC source code with preprocessor directives.

    .. versionadded:: 1.5
    eCecz*.ecz*.ehztext/x-echdrztext/x-ecsrc)+virtualr&   r    r"   propertyr1   deleter   new0renewrenew0definegetsetremote	dllexport	dllimportstdcallsubclass__on_register_module	namespaceusingtyped_object
any_objectincrefregisterwatchstopwatchingfirewatchers	watchableclass_designerclass_fixedclass_no_expansionissetclass_default_propertyproperty_category
class_dataclass_property	thisclassdbtabledbindexdatabase_opendbfieldr[   r\   )uintuint16uint32uint64boolbyteunicharint64r^   r_   z(null|value|this)\br`   ra   rb   rc   N)re   rf   rg   rh   ri   rj   rk   rl   r   r   rm   r   r   r   r   r   rn   ro   rp   rp   rp   rq   r      s0    		


r   c                   @   s  e Zd ZdZdZddgZddgZdgZdej	d	fd
e
fde
fde
fdejfdejfgdedfdejfdefdejfdejfdejfdejfdejfdefdeeejefdeeejfdefedddefedddejfd eeje
d!fd"eeje
d#fd$eeejfed%ddejfd&ejfd'efge d(e!d)ge d(e d*d+efd,ed-fgd.ed-fd/ej"fd0efdefd1efgd2ej	d3fd4ej	d-fd5ej	d-fd6efgd'ej#d-fgd7ejd-fgd8Z$d9S ):r   zW
    For Vala source code with preprocessor directives.

    .. versionadded:: 1.1
    Valavalavapiz*.valaz*.vapiztext/x-valaz^\s*#if\s+0if0r   z\s+z\\\nz//(\n|(.|\n)*?[^\\]\n)r   z[L@]?"stringz4L?'(\\.|\\[0-7]{1,3}|\\x[a-fA-F0-9]{1,2}|[^\\\'\n])'z(?s)""".*?"""z%(\d+\.\d*|\.\d+|\d+)[eE][+-]?\d+[lL]?z(\d+\.\d*|\.\d+|\d+[fF])[fF]?z0x[0-9a-fA-F]+[Ll]?z0[0-7]+[Ll]?z\d+[Ll]?z[~!%^&*+=|?:<>/-]z2(\[)(Compact|Immutable|(?:Boolean|Simple)Type)(\])z$(\[)(CCode|(?:Integer|Floating)Type)z
[()\[\],.])!r?   baser6   r>   r   	constructr7   r   r   r<   r9   enumfinallyr:   foreachr   r8   r@   islockr   outparamsrB   r   sizeofr=   r,   r$   trytypeofr;   yieldr[   r\   )r)   constdelegatedynamicensuresr3   r4   internaloverrideownedr    r!   r"   refrequiresr   r0   r%   unownedvarr   volatileweakyieldsz(namespace|using)(\s+)r   z)(class|errordomain|interface|struct)(\s+)r&   z(\.)([a-zA-Z_]\w*))voidr   chardoublefloatintint8int16int32r   longshortsize_tssize_tr   time_tucharr   uint8r   r   r   ulongr   ushortz(true|false|null)\br`   
whitespace	statementrd   z[{}];ra   r   z/\\([\\abfnrtv"\']|x[a-fA-F0-9]{2,4}|[0-7]{1,3})z	[^\\"\n]+z\\z^\s*#if.*?(?<!\\)\nz#pushz^\s*#el(?:se|if).*\nz^\s*#endif.*?(?<!\\)\nz.*?\nz[a-zA-Z_][\w.]*)r  rd   r   r  r   r   r&   r   N)%re   rf   rg   rh   ri   rj   rk   rl   r	   Preprocr   Singler   r   Charr   Floatr   Octr   r
   r   r   r   	Decoratorr   r   Declaration	Namespace	Attributerm   r   r   r   r   rn   ro   rp   rp   rp   rq   r      s    
	

/





r   c                   @   sb   e Zd ZdZdZddgZddgZdgZedZ	ed	Z
ed
ZedZedZedZdd ZdS )r   u|   
    For NVIDIA `CUDA™ <http://developer.nvidia.com/category/zone/cuda-zone>`_
    source.

    .. versionadded:: 1.6
    CUDAz*.cuz*.cuhcudacuztext/x-cuda)
__device__
__global____host____noinline____forceinline__)r  __constant__
__shared____restrict__)+char1uchar1char2uchar2char3uchar3char4uchar4short1ushort1short2ushort2short3ushort3short4ushort4int1uint1int2uint2int3uint3int4uint4long1ulong1long2ulong2long3ulong3long4ulong4	longlong1
ulonglong1	longlong2
ulonglong2float1float2float3float4double1double2dim3)gridDimblockIdxblockDim	threadIdxwarpSize)__threadfence_block__threadfence__threadfence_system__syncthreads__syncthreads_count__syncthreads_and__syncthreads_or)z<<<z>>>c                 c   s    t | |D ]D\}}}|tu rE|| jv rtj}n,|| jv r"tj}n#|| jv r+tj}n|| j	v r4tj
}n|| jv r=tj}n|| jv rEtj}|||fV  qd S N)r   get_tokens_unprocessedr   variable_qualifiersr   rm   vector_types	variablesr   execution_confsPseudofunction_qualifiersReserved	functionsFunctionselftextindextokenvaluerp   rp   rq   rQ  8  s"   





z CudaLexer.get_tokens_unprocessedN)re   rf   rg   rh   ri   rk   rj   rl   r   rW  rR  rS  rT  rY  rU  rQ  rp   rp   rp   rq   r     s    r   c                   @   s\   e Zd ZdZdZdgZddgZdgZdZdd	e	j
fd
e	fdejfegiZedZdd ZdS )r   zT
    For `SWIG <http://www.swig.org/>`_ source code.

    .. versionadded:: 2.0
    SWIGswigz*.swgz*.iz	text/swigg{Gz?rd   z(%[a-z_][a-z0-9_]*)z\$\**\&?\w+z##*[a-zA-Z_]\w*)Rz%applyz%definez	%directorz%enddefz
%exceptionz%extendz%featurez	%fragmentz%ignorez
%immutablez%importz%includez%inlinez%insertz%modulez
%newobjectz%nspacez%pragmaz%renamez%shared_ptrz	%templatez
%typecheckz%typemapz%argz
%attributez%bangz%beginz	%callbackz%catchesz%clearz	%constantz	%copyctorz%csconstz%csconstvaluez%csenumz%csmethodmodifiersz%csnothrowexceptionz%defaultz%defaultctorz%defaultdtorz%definedz%deletez
%delobjectz%descriptorz%exceptionclassz%exceptionvarz%extend_smart_pointerz
%fragmentsz%headerz%ifcplusplusz%ignorewarnz	%implicitz%implicitconvz%initz
%javaconstz%javaconstvaluez	%javaenumz%javaexceptionz%javamethodmodifiersz%kwargsz%luacodez%mutablez%naturalvarz%nestedworkaroundz	%perlcodez
%pythonabcz%pythonappendz%pythoncallbackz%pythoncodez%pythondynamicz%pythonmaybecallz%pythonnondynamicz%pythonprependz
%refobjectz%shadowz%sizeofz%trackobjectsz%typesz%unrefobjectz%varargsz%warnz%warnfilterc                 C   s:   d}t d| t j}|D ]}|tjv rd} |S d}q|S )Nr   z^\s*(%[a-z_][a-z0-9_]*)g\(\?gQ?)refindallMr   swig_directives)r]  rvmatchesmrp   rp   rq   analyse_textx  s   
zSwigLexer.analyse_textN)re   rf   rg   rh   ri   rj   rk   rl   priorityr   rZ  r	   r  r   ro   r   rf  rj  rp   rp   rp   rq   r   J  s     r   c                
   @   s   e Zd ZdZdZg dZg dZdgZdee	j
ddefee	jddejfee	jddejfee	jddejfee	jd	dd
ejfegiZdS )r   z
    For `MQL4 <http://docs.mql4.com/>`_ and
    `MQL5 <http://www.mql5.com/en/docs>`_ source code.

    .. versionadded:: 2.0
    MQL)mqlmq4mq5mql4mql5)z*.mq4z*.mq5z*.mqhz
text/x-mqlrd   r[   r\   z(clr)?)prefixr]   N)re   rf   rg   rh   ri   rj   rk   rl   r   r   keywordsr   c_typesrm   typesr   rZ  	constantsConstantcolorsr   ro   rp   rp   rp   rq   r     s"    r   c                   @   sV   e Zd ZdZdZdgZdgZdgZedZ	edZ
edZed	Zed
Zdd ZdS )r   u   
    For `Arduino(tm) <https://arduino.cc/>`_ source.

    This is an extension of the CppLexer, as the Arduino® Language is a superset
    of C++

    .. versionadded:: 2.1
    Arduinoarduinoz*.inoztext/x-arduino)setuploop)notorandxor)kDIGITAL_MESSAGEFIRMATA_STRINGANALOG_MESSAGEREPORT_DIGITALREPORT_ANALOGINPUT_PULLUPSET_PIN_MODEINTERNAL2V56SYSTEM_RESETLED_BUILTININTERNAL1V1SYSEX_STARTINTERNALEXTERNALHIGHLOWINPUTOUTPUTr  r  rC   rD   r   booleanr   zunsigned charr   r   zunsigned intwordr   zunsigned longr   r   r   r   r   arrayr0   r   r   r  r   r  r   r   r  r   r   r    r   r   operatorr   uint8_tuint16_tuint32_tuint64_tint8_tint16_tint32_tint64_tdynamic_casttypedef
const_castr   structstatic_castunionunsignedr   r   r0   r!   r   r"   friendautor   r   r3   r&   r   reinterpret_castr   r   explicitsignedr4   r   _Boolcomplex_Complex
_Imaginaryatomic_boolatomic_charatomic_scharatomic_ucharatomic_shortatomic_ushort
atomic_intatomic_uintatomic_longatomic_ulongatomic_llongatomic_ullongPROGMEM(X  KeyboardControllerMouseControllerSoftwareSerialEthernetServerEthernetClientLiquidCrystalRobotControlGSMVoiceCallEthernetUDP
EsploraTFT
HttpClient
RobotMotor
WiFiClient
GSMScanner
FileSystem	Scheduler	GSMServer	YunClient	YunServer	IPAddress	GSMClientGSMModemKeyboardEthernetConsoleGSMBandEsploraStepperProcessWiFiUDPGSM_SMSMailboxUSBHostFirmataPImageClientServerGSMPINFileIOBridgeSerialEEPROMStreamMouseAudioServoFileTaskGPRSWiFiWireTFTGSMSPISDrunShellCommandAsynchronouslyanalogWriteResolutionretrieveCallingNumberprintFirmwareVersionanalogReadResolutionsendDigitalPortPairnoListenOnLocalhostreadJoystickButtonsetFirmwareVersionreadJoystickSwitchscrollDisplayRightgetVoiceCallStatusscrollDisplayLeftwriteMicrosecondsdelayMicrosecondsbeginTransmissiongetSignalStrengthrunAsynchronouslygetAsynchronouslylistenOnLocalhostgetCurrentCarrierreadAccelerometermessageAvailablesendDigitalPortslineFollowConfigcountryNameWriterunShellCommandreadStringUntilrewindDirectoryreadTemperaturesetClockDividerreadLightSensorendTransmissionanalogReferencedetachInterruptcountryNameReadattachInterruptencryptionTypereadBytesUntilrobotNameWritereadMicrophonerobotNameReadcityNameWriteuserNameWritereadJoystickYreadJoystickXmouseReleasedopenNextFilescanNetworksnoInterruptsdigitalWritebeginSpeakermousePressedisActionDonemouseDraggeddisplayLogosnoAutoscrolladdParameterremoteNumbergetModifierskeyboardReaduserNameReadwaitContinueprocessInputparseCommandprintVersionreadNetworkswriteMessageblinkVersioncityNameReadreadMessagesetDataModeparsePacketisListeningsetBitOrderbeginPacketisDirectorymotorsWritedrawCompassdigitalReadclearScreenserialEventrightToLeftsetTextSizeleftToRightrequestFromkeyReleasedcompassReadanalogWrite
interrupts
WiFiServer
disconnect
playMelody
parseFloat
autoscroll
getPINUsed
setPINUsed
setTimeout
sendAnalog
readSlider
analogRead
beginWrite
createChar
motorsStop
keyPressed
tempoWrite
readButton
subnetMask
debugPrint
macAddress
writeGreen
randomSeed
attachGPRS
readString
sendString
remotePort
releaseAll
mouseMoved
background
getXChange
getYChange
answerCall	getResult	voiceCall	endPacket	constrain	getSocket	writeJSON	getButton	available	connected	findUntil	readBytes	exitValue	readGreen	writeBlue	startLoopr  	isPressed	sendSysex	pauseMode	gatewayIP	setCursor	getOemKey	tuneWrite	noDisplay	loadImage	switchPIN	onRequest	onReceive	changePINplayFilenoBufferparseIntoverflowcheckPINknobReadbeginTFTbitClearupdateIRbitWritepositionwriteRGBhighBytewriteRedsetSpeedreadBluenoStrokeremoteIPtransfershutdownhangCallbeginSMSendWriteattachedmaintainnoCursorcheckRegcheckPUKshiftOutisValidshiftInpulseInconnectprintlnlocalIPpinModegetIMEIdisplaynoBlinkprocessgetBandrunningbeginSDdrawBMPlowBytesetBandreleasebitReadpreparepointToreadRedsetModenoFillremovelistenstrokedetachattachnoToneexistsbufferheightbitSetcircleconfigcursorrandomIRreadsetDNSendSMSgetKeymicrosmillisbeginprintwritereadyflushwidthisPINblinkclearpressmkdirrmdirclosepointr   imageBSSIDclickdelayreadr]  movepeekbeeprectlineopenseekfillsizeturnstophomefindsteptonesqrtRSSISSIDendbittancossinpowmapabsmaxminr   runputisAlphaNumericisAlphaisAsciiisWhitespace	isControlisDigitisGraphisLowerCaseisPrintableisPunctisSpaceisUpperCaseisHexadecimalDigit)r   templatemutabler   asmtypeidtypenamer,   alignof	constexprdecltypenoexceptrX   thread_localrestrictc                 c   s    t | |D ]J\}}}|| jv r|tj|fV  q|| jv r%|t|fV  q|| jv r2|tj	|fV  q|| j
v r>|t|fV  q|| jv rK|tj|fV  q|||fV  qd S rP  )r   rQ  	structurer   r   	operatorsr
   rT  r   rX  suppress_highlightrY  rZ  r[  rp   rp   rq   rQ    s   




z#ArduinoLexer.get_tokens_unprocessedN)re   rf   rg   rh   ri   rj   rk   rl   r   r  r  rT  rY  r  rQ  rp   rp   rp   rq   r     s    	Ar   )!rh   rc  pygments.lexerr   r   r   r   r   r   pygments.tokenr   r	   r
   r   r   r   r   r   pygments.lexers.c_cppr   r   pygments.lexersr   __all__r   r   r   r   r   r   r   r   r   rp   rp   rp   rq   <module>   s    
 ((3&b0=