* lisp/progmodes/go-ts-mode.el (go-ts-mode--font-lock-settings):
Handle multiple const_spec identifiers.
* test/lisp/progmodes/go-ts-mode-resources/font-lock.go:
Add test case.
(cherry picked from commit
b531bbf73ef91aca0a699ffc89e6b93dc49d0151)
,@(when (go-ts-mode--iota-query-supported-p)
'((iota) @font-lock-constant-face))
(const_declaration
- (const_spec name: (identifier) @font-lock-constant-face)))
+ (const_spec name: (identifier) @font-lock-constant-face
+ ("," name: (identifier) @font-lock-constant-face)*)))
:language 'go
:feature 'delimiter
// ^ font-lock-variable-name-face
for idx := 0; idx < n; idx++ {}
// ^ font-lock-variable-name-face
+
+const (
+ zero, one = 0, 1
+// ^ font-lock-constant-face
+// ^ font-lock-constant-face
+)