Skip to content

Commit fca57b3

Browse files
committed
emacs: do not highlight #foo] as an attribute
part of #14347
1 parent 4fdc27e commit fca57b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/etc/emacs/rust-mode.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@
213213
(,(regexp-opt rust-special-types 'words) . font-lock-type-face)
214214

215215
;; Attributes like `#[bar(baz)]` or `#![bar(baz)]`
216-
(,(rust-re-grab (concat "#\\!?[" rust-re-ident "[^]]*\\]"))
216+
(,(rust-re-grab (concat "#\\!?\\[" rust-re-ident "[^]]*\\]"))
217217
1 font-lock-preprocessor-face)
218218

219219
;; Syntax extension invocations like `foo!`, highlight including the !

0 commit comments

Comments
 (0)