Skip to content

Commit 689510d

Browse files
committed
Merge pull request #321 from syohex/colons-in-binaries
Fix invalid highlighting '::' in binaries
2 parents 65f9114 + 498bebe commit 689510d

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

elixir-mode.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,7 @@ is used to limit the scan."
424424
1 elixir-ignored-var-face)
425425

426426
;; Map keys
427-
(,(elixir-rx (group (and (one-or-more identifiers) ":")))
427+
(,(elixir-rx (group (and (one-or-more identifiers) ":")) space)
428428
1 elixir-atom-face)
429429

430430
;; Pseudovariables

test/elixir-mode-font-test.el

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,12 @@ true_false_nil
222222
(should (eq (elixir-test-face-at 3) 'elixir-atom-face))
223223
(should (eq (elixir-test-face-at 4) 'elixir-atom-face))
224224
(should (eq (elixir-test-face-at 9) 'elixir-atom-face))
225-
(should (eq (elixir-test-face-at 10) 'elixir-atom-face))))
225+
(should (eq (elixir-test-face-at 10) 'elixir-atom-face)))
226+
227+
;; https://github.com/elixir-lang/emacs-elixir/issues/320
228+
(elixir-test-with-temp-buffer
229+
"<<foo::bar>>"
230+
(should-not (eq (elixir-test-face-at 3) 'elixir-atom-face))))
226231

227232
(ert-deftest elixir-mode-syntax-table/fontify-interpolation ()
228233
:tags '(fontification interpolation syntax-table)

0 commit comments

Comments
 (0)