aboutsummaryrefslogtreecommitdiffhomepage
path: root/lexers/LexRust.cxx
diff options
context:
space:
mode:
authorSiegeLord <slabode@aim.com>2014-07-29 11:58:21 -0400
committerSiegeLord <slabode@aim.com>2014-07-29 11:58:21 -0400
commit57b506e7569aadfe1b9b09c6c4f210e5b22dca1b (patch)
tree6631ba29b38b26e34b2d14a727917837619f9091 /lexers/LexRust.cxx
parentfb799d1e2945952169cf2d2f67a36017edadfafd (diff)
downloadscintilla-mirror-57b506e7569aadfe1b9b09c6c4f210e5b22dca1b.tar.gz
Rust: Update hashbang comment syntax.
Hashbang comments that start with the following 3 characters: #![ do not count as hashbang comments, but rather some other syntax (inner attribute).
Diffstat (limited to 'lexers/LexRust.cxx')
-rw-r--r--lexers/LexRust.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/lexers/LexRust.cxx b/lexers/LexRust.cxx
index 8a3020532..0d1106849 100644
--- a/lexers/LexRust.cxx
+++ b/lexers/LexRust.cxx
@@ -645,7 +645,7 @@ void SCI_METHOD LexerRust::Lex(unsigned int startPos, int length, int initStyle,
int n = styler.SafeGetCharAt(pos + 1, '\0');
int n2 = styler.SafeGetCharAt(pos + 2, '\0');
- if (pos == 0 && c == '#' && n == '!') {
+ if (pos == 0 && c == '#' && n == '!' && n2 != '[') {
pos += 2;
ResumeLineComment(styler, pos, max, NotDocComment);
} else if (IsWhitespace(c)) {