|e ldZddlmZmZmZmZmZddlmZm Z m Z m Z m Z m Z mZmZmZdgZGddeZy)z pygments.lexers.rust ~~~~~~~~~~~~~~~~~~~~ Lexers for the Rust language. :copyright: Copyright 2006-2023 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. ) RegexLexerincludebygroupswordsdefault) TextCommentOperatorKeywordNameStringNumber Punctuation Whitespace RustLexercHeZdZdZdZdZddgZddgZdd gZe d d e jfZ e d d e jfZe dd e j j"fZdej(fedggdefdefdej0fdej0fdej2fdej0dfdej0dfdej4dfdej(fe dd e fe dd e j6fde j8fd e jj:fd!e d"fd#e j<fd$e d%fd&e d'fd(ee e e fe d)e jj:feed*e fd+e d'fd,ee e j,e jBfd-ejDfd.ejDfd/e#jHd0fd1e#jJd0fd2e#jLd0fd3e#jNd0fd4e#jPd0fd5ed6fd7ed8fd9efd:e)d;fde)fd?e fd@e fdAej(dBfdCe fdDej4fdej4dEfdFej4dGfdHej4fgdDej0fdej0dEfdFej0dGfdHej0fgde fd?e jVdGfedGgde fd?e j dGfedGgde fdIe j:fd:e)d;fee d?e jXdGfedGgdJe jfdKe jZfedGgdLe dGfdMe dGfedGgd7edGfdNej\fdOefdPefgdQej\fe/d8gd7ed8fdRej(dBfge/dSdTej(dGfdUej(fgdV Z0yW)Xrz\ Lexer for the Rust programming language (version 1.47). .. versionadded:: 1.6 Rustzhttps://www.rust-lang.org/z*.rsz*.rs.inrustrsz text/rustz text/x-rust)u8u16u32u64u128i8i16i32i64i128usizeisizef32f64charstrboolz\b)suffix)$CopySendSizedSyncUnpinDropFnFnMutFnOncedropBoxToOwnedClone PartialEq PartialOrdEqOrdAsRefAsMutIntoFromDefaultIteratorExtend IntoIteratorDoubleEndedIteratorExactSizeIteratorOptionSomeNoneResultOkErrr ToStringVec)2asmassert assert_eq assert_necfgcolumn compile_errorconcat concat_identsdbg debug_assertdebug_assert_eqdebug_assert_neenveprinteprintlnfileformat format_argsformat_args_nl global_asmr include_bytes include_stris_aarch64_feature_detectedis_arm_feature_detectedis_mips64_feature_detectedis_mips_feature_detectedis_powerpc64_feature_detectedis_powerpc_feature_detectedis_x86_feature_detectedlinellvm_asm log_syntax macro_rulesmatches module_path option_envpanicprintprintln stringify thread_localtodo trace_macros unimplemented unreachablevecwritewriteln!z #![^[\r\n].*$basez\nz\s+z//!.*?\nz///(\n|[^/].*?\n)z //(.*?)\nz/\*\*(\n|[^/*]) doccommentz/\*!z/\*commentz\$([a-zA-Z_]\w*|\(,?|\),?|,?))asasyncawaitboxconstcratedynelseexternforifimplinloopmatchmovemutpubrefreturnstaticsupertraitunsafeusewherewhile) abstractbecomedofinalmacrooverrideprivtypeoftryunsizedvirtualyieldz(true|false)\bzself\bzmod\bmodnamezlet\bzfn\bfuncnamez(struct|enum|type|union)\btypenamez(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}rr~rrrrrrrrrN)1__name__ __module__ __qualname____doc__nameurl filenamesaliases mimetypesrr Type keyword_typesr Builtinbuiltin_funcs_typesFunctionMagicbuiltin_macrosr Preprocrrr DocSingle MultilineReservedConstantPseudo DeclarationrrLabelCharrBinOctHexFloatIntegerr r NamespaceClass AttributeEscapertokens6/usr/lib/python3/dist-packages/pygments/lexers/rust.pyrrsG D &C#ItnGm,Ill$M ! " ll $"#"]]((#*N.w / FO  W J W Z W &** % W "6:: . W 7>> * W  \ :W fjj, /W W&& 2W 27?? CW I !#*  +W &L!")"2"2 4'W , 0 0 1-W . ++ ,/W 0w *1W 2w** +3W 4gz *5W 6+GZ @7W 8*8GT7+K L9W : ;W <4<<.. /=W @ AW B CW FdOGW J$ +KW N9 gt ; =OW V1 [[ WW \1 [[ ]W f&**l 3gW j6::| 4kW n#FJJ =oW r34:LL  sW xfnnl ;yW ~FL )W @68 $AW B#F +CW H8Z (IW N !OW P{ +QW R$X .SW Xd #YW \ %]W bw 5cW l4LmW r)) * W&& 0 W&& / g'' (   # VZZ ) VZZ ( fjj !  TN dnnf 5 FO TN dmmV 4 FO TN 7>> " 8Z (   djj& 1 FO DLL ) t~~ . FO &w 7 '6 * FO 66 "-.4mm =  FO  -fmm < H  68 $ GOO\ 2 & ' GOOV , 7?? + o\FrN)rpygments.lexerrrrrrpygments.tokenrr r r r r rrr__all__rrrrrs9IH$$$ -M Mr