summaryrefslogtreecommitdiff
path: root/pygments
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2014-10-07 15:24:28 +0200
committerGeorg Brandl <georg@python.org>2014-10-07 15:24:28 +0200
commita8053d446a08ac51e674e96a688046c0e5568968 (patch)
tree632841b40f29fdf5a2ff19da52e59d262576bff8 /pygments
parentdb288cd60ae8d92f6aa95a7061a43f24d2637b48 (diff)
downloadpygments-a8053d446a08ac51e674e96a688046c0e5568968.tar.gz
Closes #972: accept "inner attribute" syntax for Rust.
Diffstat (limited to 'pygments')
-rw-r--r--pygments/lexers/rust.py2
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,