diff options
author | Georg Brandl <georg@python.org> | 2020-11-19 07:58:30 +0100 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2020-11-19 07:58:30 +0100 |
commit | a34b77df1d10e91cd107279a33876943717505bf (patch) | |
tree | ba6baeb9967a3a0d2ab56c7717e205861137194d /pygments | |
parent | 1ee43509faf86f5661cb7f2a06d53429eb349697 (diff) | |
download | pygments-git-a34b77df1d10e91cd107279a33876943717505bf.tar.gz |
minor variable name fixup
Diffstat (limited to 'pygments')
-rw-r--r-- | pygments/lexers/rust.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/pygments/lexers/rust.py b/pygments/lexers/rust.py index 0d4bf5fc..727367ce 100644 --- a/pygments/lexers/rust.py +++ b/pygments/lexers/rust.py @@ -32,7 +32,7 @@ class RustLexer(RegexLexer): 'usize', 'isize', 'f32', 'f64', 'char', 'str', 'bool', ), suffix=r'\b'), Keyword.Type) - builtin_types = (words(( + builtin_funcs_types = (words(( 'Send', 'Sized', 'Sync', 'Unpin', 'Drop', 'Fn', 'FnMut', 'FnOnce', 'AsRef', 'AsMut', 'Into', 'From', @@ -43,7 +43,7 @@ class RustLexer(RegexLexer): 'PartialOrd', 'Ord', 'drop', 'Some', 'None', 'Ok', 'Err', ), suffix=r'\b'), Name.Builtin) - builtin_funcs_macros = (words(( + builtin_macros = (words(( 'asm!', 'assert!', 'assert_eq!', 'assert_ne!', 'cfg!', 'column!', 'compile_error!', 'concat!', 'concat_idents!', 'dbg!', 'debug_assert!', 'debug_assert_eq!', 'debug_assert_ne!', 'env!', 'eprint!', 'eprintln!', @@ -94,8 +94,8 @@ class RustLexer(RegexLexer): keyword_types, (r'[sS]elf\b', Name.Builtin.Pseudo), # Prelude (taken from Rust's src/libstd/prelude.rs) - builtin_types, - builtin_funcs_macros, + builtin_funcs_types, + builtin_macros, # Path seperators, so types don't catch them. (r'::\b', Text), # Types in positions. @@ -171,7 +171,7 @@ class RustLexer(RegexLexer): (r'\s+', Text), (r'&', Keyword.Pseudo), (r"'", Operator, 'lifetime'), - builtin_types, + builtin_funcs_types, keyword_types, (r'[a-zA-Z_]\w*', Name.Class, '#pop'), default('#pop'), |