diff options
author | Georg Brandl <georg@python.org> | 2014-10-07 15:24:28 +0200 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2014-10-07 15:24:28 +0200 |
commit | a8053d446a08ac51e674e96a688046c0e5568968 (patch) | |
tree | 632841b40f29fdf5a2ff19da52e59d262576bff8 /pygments | |
parent | db288cd60ae8d92f6aa95a7061a43f24d2637b48 (diff) | |
download | pygments-a8053d446a08ac51e674e96a688046c0e5568968.tar.gz |
Closes #972: accept "inner attribute" syntax for Rust.
Diffstat (limited to 'pygments')
-rw-r--r-- | pygments/lexers/rust.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pygments/lexers/rust.py b/pygments/lexers/rust.py index 87bdcc5e..b4acbbd1 100644 --- a/pygments/lexers/rust.py +++ b/pygments/lexers/rust.py @@ -112,7 +112,7 @@ class RustLexer(RegexLexer): (r'[a-zA-Z_]\w*', Name), # Attributes - (r'#\[', Comment.Preproc, 'attribute['), + (r'#!?\[', Comment.Preproc, 'attribute['), # Macros (r'([A-Za-z_]\w*)(!)(\s*)([A-Za-z_]\w*)?(\s*)(\{)', bygroups(Comment.Preproc, Punctuation, Whitespace, Name, |