File: //opt/saltstack/salt/lib/python3.10/site-packages/pygments/lexers/__pycache__/rust.cpython-310.pyc
o
;jG � @ sf d Z ddlmZmZmZmZmZ ddlmZm Z m
Z
mZmZm
Z
mZmZmZ dgZG dd� de�ZdS )z�
pygments.lexers.rust
~~~~~~~~~~~~~~~~~~~~
Lexers for the Rust language.
:copyright: Copyright 2006-present by the Pygments team, see AUTHORS.
:license: BSD, see LICENSE for details.
� )�
RegexLexer�include�bygroups�words�default) �Text�Comment�Operator�Keyword�Name�String�Number�Punctuation�
Whitespace� RustLexerc @ st e Zd ZdZdZdZddgZddgZdd gZd
Z e
ddd
�ejfZ
e
ddd
�ejfZe
ddd
�ejjfZdejfed�gg def�def�dejf�dejf�dejf�dejdf�dejdf�dejdf�dejf�e
ddd
�ef�e
ddd
�ejf�d ejf�d!ejjf�d"ed#f�d$ejf�d%ed&f�d'ed(f�d)e eee�f�e
�d*ejjf�e�e�d+e!f�d,e!d(f�d-e ee"jej#�f�d.ej$f�d/ej$f�d0e%j&d1f�d2e%j'd1f�d3e%j(d1f�d4e%j)d1f�d5e%j*d1f�d6ed7f�d8ed9f�d:ef�d;e+d<f�d=e+f�d>e!f�d?e+f�d@ef�dAef�dBejdCf�dDe!f�dEejfdejdFfdGejdHfdIejfgdEejfdejdFfdGejdHfdIejfgdefd@ej,dHfedH�gdefd@ejdHfedH�gdefdJejfd;e+d<fee
d@ej-dHfedH�gdKejfdLej.fedH�gdMedHfdNedHfedH�gd8edHfdOej/fdPefdQefgdRej/fe0d9�gd8ed9fdSejdCfge0dT�dUejdHfdVejfgdW�
Z1dXS )Yr zA
Lexer for the Rust programming language (version 1.47).
ZRustzhttps://www.rust-lang.org/z*.rsz*.rs.inZrustZrsz text/rustztext/x-rustz1.6)�u8�u16�u32Zu64Zu128Zi8Zi16Zi32Zi64Zi128ZusizeZisizeZf32Zf64�char�str�boolz\b)�suffix)$ZCopyZSend�SizedZSyncZUnpinZDropZFnZFnMutZFnOnceZdropZBoxZToOwnedZCloneZ PartialEqZ
PartialOrdZEqZOrdZAsRefZAsMutZIntoZFromZDefault�IteratorZExtendZIntoIteratorZDoubleEndedIteratorZExactSizeIteratorZOptionZSome�NoneZResultZOkZErrr ZToStringZVec)2Zasm�assertZ assert_eqZ assert_neZcfg�columnZ
compile_error�concatZ
concat_identsZdbgZdebug_assertZdebug_assert_eqZdebug_assert_ne�envZeprintZeprintln�file�formatZformat_argsZformat_args_nlZ
global_asmr Z
include_bytesZinclude_strZis_aarch64_feature_detectedZis_arm_feature_detectedZis_mips64_feature_detectedZis_mips_feature_detectedZis_powerpc64_feature_detectedZis_powerpc_feature_detectedZis_x86_feature_detected�lineZllvm_asmZ
log_syntaxZmacro_rules�matchesZmodule_pathZ
option_envZpanic�printZprintlnZ stringifyZthread_localZtodoZtrace_macrosZ
unimplementedZunreachableZvec�writeZwriteln�!z
#![^[\r\n].*$�basez\nz\s+z//!.*?\nz///(\n|[^/].*?\n)z //(.*?)\nz/\*\*(\n|[^/*])�
doccommentz/\*!z/\*�commentz\$([a-zA-Z_]\w*|\(,?|\),?|,?))�as�async�awaitZbox�constZcrateZdyn�elseZextern�for�if�impl�inZloop�match�moveZmutZpub�ref�returnZstatic�superZtraitZunsafeZuse�where�while)ZabstractZbecomeZdo�finalZmacro�overrideZprivZtypeof�tryZunsizedZvirtual�yieldz(true|false)\bzself\bzmod\b�modnamezlet\bzfn\b�funcnamez(struct|enum|type|union)\b�typenamez(default)(\s+)(type|fn)\bz [sS]elf\bz::\bz(?::|->)z((break|continue)(\b\s*)(\'[A-Za-z_]\w*)?zA'(\\['"\\nrt]|\\x[0-7][0-9a-fA-F]|\\0|\\u\{[0-9a-fA-F]{1,6}\}|.)'z@b'(\\['"\\nrt]|\\x[0-9a-fA-F]{2}|\\0|\\u\{[0-9a-fA-F]{1,6}\}|.)'z0b[01_]+�
number_litz 0o[0-7_]+z0[xX][0-9a-fA-F_]+zJ[0-9][0-9_]*(\.[0-9_]+[eE][+\-]?[0-9_]+|\.[0-9_]*(?!\.)|[eE][+\-]?[0-9_]+)z[0-9][0-9_]*zb"�
bytestring�"�stringz(?s)b?r(#*)".*?"\1�'�lifetimez\.\.=?z
[{}()\[\],.;]z[+\-*/%&|<>^!~@=:?]z[a-zA-Z_]\w*zr#[a-zA-Z_]\w*z#!?\[�
attribute[�#z[^*/]+z#pushz\*/z#popz[*/]�&z
(static|_)z
[a-zA-Z_]+\w*z[ui](8|16|32|64|size)zf(32|64)z;\\['"\\nrt]|\\x[0-7][0-9a-fA-F]|\\0|\\u\{[0-9a-fA-F]{1,6}\}z[^\\"]+z\\z\\x[89a-fA-F][0-9a-fA-F]z\[�attribute_commonz\]z [^"\]\[]+)
�rootr&