* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
@ 2024-05-26 12:41 Noah Peart
2024-05-28 2:46 ` Randy Taylor
0 siblings, 1 reply; 20+ messages in thread
From: Noah Peart @ 2024-05-26 12:41 UTC (permalink / raw)
To: 71209
[-- Attachment #1.1: Type: text/plain, Size: 964 bytes --]
Tags: patch
Adds font-locking rule in go-ts-mode to give variables in range clauses
font-lock-variable-name-face (in feature 'definition).
For example, the following font-locking is added:
for idx, val := range arr {}
// ^ font-lock-variable-name-face
// ^ font-lock-variable-name-face
The patch also adds a test case.
In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
3.24.33, cairo version 1.16.0) of 2024-05-21 built on noah-X580VD
Repository revision: 63d914e377f7cc37056de2503bfbeea831875037
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12101004
System Description: Ubuntu 22.04.4 LTS
Configured using:
'configure --prefix=/usr/local --with-modules --with-tree-sitter
--with-threads --with-x-toolkit=gtk3 --with-xwidgets --with-gnutls
--with-json --with-mailutils --with-jpeg --with-png --with-rsvg
--with-tiff --with-xml2 --with-xpm --with-imagemagick CC=gcc-12
CXX=gcc-12'
[-- Attachment #1.2: Type: text/html, Size: 1098 bytes --]
[-- Attachment #2: 0001-Add-font-locking-for-variables-in-go-ts-mode-range-c.patch --]
[-- Type: text/x-patch, Size: 2691 bytes --]
From 1b6b2a7001ff079d81af7d42c7ee98e8e7318390 Mon Sep 17 00:00:00 2001
From: Noah Peart <noah.v.peart@gmail.com>
Date: Sun, 26 May 2024 05:34:34 -0700
Subject: [PATCH] Add font-locking for variables in go-ts-mode range clauses
* lisp/progmodes/go-ts-mode.el (go-ts-mode--font-lock-settings):
Add font-locking rule for variable names in range clauses.
* test/lisp/progmodes/go-ts-mode-tests.el (go-ts-test-font-lock):
Add font-locking test for go-ts-mode.
* test/lisp/progmodes/go-ts-mode-resources/font-lock.go: New file
for go-ts-mode font-locking tests.
---
lisp/progmodes/go-ts-mode.el | 5 ++++-
test/lisp/progmodes/go-ts-mode-resources/font-lock.go | 5 +++++
test/lisp/progmodes/go-ts-mode-tests.el | 5 +++++
3 files changed, 14 insertions(+), 1 deletion(-)
create mode 100644 test/lisp/progmodes/go-ts-mode-resources/font-lock.go
diff --git a/lisp/progmodes/go-ts-mode.el b/lisp/progmodes/go-ts-mode.el
index aef224ab3fa..43f7e042590 100644
--- a/lisp/progmodes/go-ts-mode.el
+++ b/lisp/progmodes/go-ts-mode.el
@@ -180,7 +180,10 @@ go-ts-mode--font-lock-settings
(identifier) @font-lock-variable-name-face
("," (identifier) @font-lock-variable-name-face)*))
(var_spec name: (identifier) @font-lock-variable-name-face
- ("," name: (identifier) @font-lock-variable-name-face)*))
+ ("," name: (identifier) @font-lock-variable-name-face)*)
+ (range_clause
+ left: (expression_list
+ (identifier) @font-lock-variable-name-face)))
:language 'go
:feature 'function
diff --git a/test/lisp/progmodes/go-ts-mode-resources/font-lock.go b/test/lisp/progmodes/go-ts-mode-resources/font-lock.go
new file mode 100644
index 00000000000..4e7a8e1710b
--- /dev/null
+++ b/test/lisp/progmodes/go-ts-mode-resources/font-lock.go
@@ -0,0 +1,5 @@
+for idx, val := range arr {}
+// ^ font-lock-variable-name-face
+// ^ font-lock-variable-name-face
+for idx := 0; idx < n; idx++ {}
+// ^ font-lock-variable-name-face
diff --git a/test/lisp/progmodes/go-ts-mode-tests.el b/test/lisp/progmodes/go-ts-mode-tests.el
index fd9b57e8691..f36dbde5103 100644
--- a/test/lisp/progmodes/go-ts-mode-tests.el
+++ b/test/lisp/progmodes/go-ts-mode-tests.el
@@ -27,5 +27,10 @@ go-ts-mode-test-indentation
(skip-unless (treesit-ready-p 'go))
(ert-test-erts-file (ert-resource-file "indent.erts")))
+(ert-deftest go-ts-test-font-lock ()
+ (skip-unless (treesit-ready-p 'go))
+ (let ((treesit-font-lock-level 4))
+ (ert-font-lock-test-file (ert-resource-file "font-lock.go") 'go-ts-mode)))
+
(provide 'go-ts-mode-tests)
;;; go-ts-mode-tests.el ends here
--
2.34.1
^ permalink raw reply related [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-05-26 12:41 bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses Noah Peart
@ 2024-05-28 2:46 ` Randy Taylor
2024-05-30 13:25 ` Noah Peart
0 siblings, 1 reply; 20+ messages in thread
From: Randy Taylor @ 2024-05-28 2:46 UTC (permalink / raw)
To: Noah Peart; +Cc: 71209
On Sunday, May 26th, 2024 at 08:41, Noah Peart <noah.v.peart@gmail.com> wrote:
> Tags: patch
>
> Adds font-locking rule in go-ts-mode to give variables in range clauses
> font-lock-variable-name-face (in feature 'definition).
>
> For example, the following font-locking is added:
>
> for idx, val := range arr {}
> // ^ font-lock-variable-name-face
> // ^ font-lock-variable-name-face
>
> The patch also adds a test case.
>
>
> In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
> 3.24.33, cairo version 1.16.0) of 2024-05-21 built on noah-X580VD
> Repository revision: 63d914e377f7cc37056de2503bfbeea831875037
> Repository branch: master
> Windowing system distributor 'The X.Org Foundation', version 11.0.12101004
> System Description: Ubuntu 22.04.4 LTS
>
> Configured using:
> 'configure --prefix=/usr/local --with-modules --with-tree-sitter
> --with-threads --with-x-toolkit=gtk3 --with-xwidgets --with-gnutls
> --with-json --with-mailutils --with-jpeg --with-png --with-rsvg
> --with-tiff --with-xml2 --with-xpm --with-imagemagick CC=gcc-12
> CXX=gcc-12'
Thanks, but it seems we already highlight this when at treesit-font-lock-level 4?
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-05-28 2:46 ` Randy Taylor
@ 2024-05-30 13:25 ` Noah Peart
2024-05-30 23:23 ` Dmitry Gutov
2024-06-01 1:09 ` Randy Taylor
0 siblings, 2 replies; 20+ messages in thread
From: Noah Peart @ 2024-05-30 13:25 UTC (permalink / raw)
To: Randy Taylor; +Cc: 71209
[-- Attachment #1: Type: text/plain, Size: 1570 bytes --]
> it seems we already highlight this when at treesit-font-lock-level 4?
They get highlighted with `font-lock-variable-use-face` at level 4, but
shouldn't
they be getting `font-lock-variable-name-face` in the 'definition feature?
On Mon, May 27, 2024 at 7:46 PM Randy Taylor <dev@rjt.dev> wrote:
> On Sunday, May 26th, 2024 at 08:41, Noah Peart <noah.v.peart@gmail.com>
> wrote:
>
> > Tags: patch
> >
> > Adds font-locking rule in go-ts-mode to give variables in range clauses
> > font-lock-variable-name-face (in feature 'definition).
> >
> > For example, the following font-locking is added:
> >
> > for idx, val := range arr {}
> > // ^ font-lock-variable-name-face
> > // ^ font-lock-variable-name-face
> >
> > The patch also adds a test case.
> >
> >
> > In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
> > 3.24.33, cairo version 1.16.0) of 2024-05-21 built on noah-X580VD
> > Repository revision: 63d914e377f7cc37056de2503bfbeea831875037
> > Repository branch: master
> > Windowing system distributor 'The X.Org Foundation', version
> 11.0.12101004
> > System Description: Ubuntu 22.04.4 LTS
> >
> > Configured using:
> > 'configure --prefix=/usr/local --with-modules --with-tree-sitter
> > --with-threads --with-x-toolkit=gtk3 --with-xwidgets --with-gnutls
> > --with-json --with-mailutils --with-jpeg --with-png --with-rsvg
> > --with-tiff --with-xml2 --with-xpm --with-imagemagick CC=gcc-12
> > CXX=gcc-12'
>
> Thanks, but it seems we already highlight this when at
> treesit-font-lock-level 4?
>
[-- Attachment #2: Type: text/html, Size: 2104 bytes --]
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-05-30 13:25 ` Noah Peart
@ 2024-05-30 23:23 ` Dmitry Gutov
2024-06-01 1:09 ` Randy Taylor
1 sibling, 0 replies; 20+ messages in thread
From: Dmitry Gutov @ 2024-05-30 23:23 UTC (permalink / raw)
To: Noah Peart, Randy Taylor; +Cc: 71209
On 30/05/2024 16:25, Noah Peart wrote:
> > it seems we already highlight this when at treesit-font-lock-level 4?
>
> They get highlighted with `font-lock-variable-use-face` at level 4, but
> shouldn't
> they be getting `font-lock-variable-name-face` in the 'definition feature?
I think that's a good idea: the local variables idx and val are
introduced on that line, so we could indeed call those occurrences
"definitions".
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-05-30 13:25 ` Noah Peart
2024-05-30 23:23 ` Dmitry Gutov
@ 2024-06-01 1:09 ` Randy Taylor
2024-06-01 1:42 ` Noah Peart
2024-06-01 1:56 ` Dmitry Gutov
1 sibling, 2 replies; 20+ messages in thread
From: Randy Taylor @ 2024-06-01 1:09 UTC (permalink / raw)
To: Noah Peart; +Cc: 71209, Dmitry Gutov
On Thursday, May 30th, 2024 at 09:25, Noah Peart <noah.v.peart@gmail.com> wrote:
> > it seems we already highlight this when at treesit-font-lock-level 4?
> They get highlighted with `font-lock-variable-use-face` at level 4, but shouldn't
> they be getting `font-lock-variable-name-face` in the 'definition feature?
>
Indeed, thanks. Could someone please install the patch? Thanks in advance.
Seems like c++-ts-mode will need to get updated too, as with:
for (const auto& i : things) {}
i gets font-lock-variable-use-face. I wonder if any other ts modes
have similar issues.
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:09 ` Randy Taylor
@ 2024-06-01 1:42 ` Noah Peart
2024-06-01 1:50 ` Noah Peart
` (2 more replies)
2024-06-01 1:56 ` Dmitry Gutov
1 sibling, 3 replies; 20+ messages in thread
From: Noah Peart @ 2024-06-01 1:42 UTC (permalink / raw)
To: Randy Taylor; +Cc: 71209, Dmitry Gutov
[-- Attachment #1: Type: text/plain, Size: 1251 bytes --]
> c++-ts-mode will need to get updated too
I've been using these for c++, I think they are still missing
;; for (auto x: ...)
(for_range_loop
declarator: (identifier) @font-lock-variable-name-face)
;; auto& x
(reference_declarator
(identifier) @font-lock-variable-name-face)
;; auto[&] [x, y]
(structured_binding_declarator
_ [(identifier)] @font-lock-variable-name-face)
I suppose most people keep the default font-locking for variable-name
and variable-use, so these missing rules go unnoticed.
On Fri, May 31, 2024 at 6:09 PM Randy Taylor <dev@rjt.dev> wrote:
> On Thursday, May 30th, 2024 at 09:25, Noah Peart <noah.v.peart@gmail.com>
> wrote:
> > > it seems we already highlight this when at treesit-font-lock-level 4?
> > They get highlighted with `font-lock-variable-use-face` at level 4, but
> shouldn't
> > they be getting `font-lock-variable-name-face` in the 'definition
> feature?
> >
>
> Indeed, thanks. Could someone please install the patch? Thanks in advance.
>
> Seems like c++-ts-mode will need to get updated too, as with:
> for (const auto& i : things) {}
> i gets font-lock-variable-use-face. I wonder if any other ts modes
> have similar issues.
>
[-- Attachment #2: Type: text/html, Size: 1768 bytes --]
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:42 ` Noah Peart
@ 2024-06-01 1:50 ` Noah Peart
2024-06-01 14:13 ` Dmitry Gutov
2024-06-01 1:51 ` Dmitry Gutov
2024-06-01 14:13 ` Dmitry Gutov
2 siblings, 1 reply; 20+ messages in thread
From: Noah Peart @ 2024-06-01 1:50 UTC (permalink / raw)
To: Randy Taylor; +Cc: 71209, Dmitry Gutov
[-- Attachment #1: Type: text/plain, Size: 1684 bytes --]
There is a similar issue with font-lock-property-name-face
and font-lock-property-use-face. I've noticed different modes
treat things differently. I think object fields in literals should get
property-name-face, but json-ts-mode, for example,
doesn't use font-lock-property-name-face at all.
On Fri, May 31, 2024 at 6:42 PM Noah Peart <noah.v.peart@gmail.com> wrote:
> > c++-ts-mode will need to get updated too
>
> I've been using these for c++, I think they are still missing
>
> ;; for (auto x: ...)
> (for_range_loop
> declarator: (identifier) @font-lock-variable-name-face)
> ;; auto& x
> (reference_declarator
> (identifier) @font-lock-variable-name-face)
> ;; auto[&] [x, y]
> (structured_binding_declarator
> _ [(identifier)] @font-lock-variable-name-face)
>
> I suppose most people keep the default font-locking for variable-name
> and variable-use, so these missing rules go unnoticed.
>
> On Fri, May 31, 2024 at 6:09 PM Randy Taylor <dev@rjt.dev> wrote:
>
>> On Thursday, May 30th, 2024 at 09:25, Noah Peart <noah.v.peart@gmail.com>
>> wrote:
>> > > it seems we already highlight this when at treesit-font-lock-level 4?
>> > They get highlighted with `font-lock-variable-use-face` at level 4, but
>> shouldn't
>> > they be getting `font-lock-variable-name-face` in the 'definition
>> feature?
>> >
>>
>> Indeed, thanks. Could someone please install the patch? Thanks in advance.
>>
>> Seems like c++-ts-mode will need to get updated too, as with:
>> for (const auto& i : things) {}
>> i gets font-lock-variable-use-face. I wonder if any other ts modes
>> have similar issues.
>>
>
[-- Attachment #2: Type: text/html, Size: 2498 bytes --]
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:42 ` Noah Peart
2024-06-01 1:50 ` Noah Peart
@ 2024-06-01 1:51 ` Dmitry Gutov
2024-06-01 1:56 ` Noah Peart
2024-06-01 14:13 ` Dmitry Gutov
2 siblings, 1 reply; 20+ messages in thread
From: Dmitry Gutov @ 2024-06-01 1:51 UTC (permalink / raw)
To: Noah Peart, Randy Taylor; +Cc: 71209
On 01/06/2024 04:42, Noah Peart wrote:
> I suppose most people keep the default font-locking for variable-name
> and variable-use, so these missing rules go unnoticed.
Only if you set treesit-font-lock-level to 4, right?
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:51 ` Dmitry Gutov
@ 2024-06-01 1:56 ` Noah Peart
2024-06-01 1:59 ` Dmitry Gutov
0 siblings, 1 reply; 20+ messages in thread
From: Noah Peart @ 2024-06-01 1:56 UTC (permalink / raw)
To: Dmitry Gutov; +Cc: 71209, Randy Taylor
[-- Attachment #1: Type: text/plain, Size: 558 bytes --]
> Only if you set treesit-font-lock-level to 4, right?
Yea, that's true - I assumed most people(?) do, but I just realized
I hadn't been doing that for years until tree-sitter - and now I've
become obsessive compulsive about my fonts.
On Fri, May 31, 2024 at 6:51 PM Dmitry Gutov <dmitry@gutov.dev> wrote:
> On 01/06/2024 04:42, Noah Peart wrote:
> > I suppose most people keep the default font-locking for variable-name
> > and variable-use, so these missing rules go unnoticed.
>
> Only if you set treesit-font-lock-level to 4, right?
>
[-- Attachment #2: Type: text/html, Size: 919 bytes --]
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:09 ` Randy Taylor
2024-06-01 1:42 ` Noah Peart
@ 2024-06-01 1:56 ` Dmitry Gutov
1 sibling, 0 replies; 20+ messages in thread
From: Dmitry Gutov @ 2024-06-01 1:56 UTC (permalink / raw)
To: Randy Taylor, Noah Peart; +Cc: 71209
On 01/06/2024 04:09, Randy Taylor wrote:
> On Thursday, May 30th, 2024 at 09:25, Noah Peart <noah.v.peart@gmail.com> wrote:
>>> it seems we already highlight this when at treesit-font-lock-level 4?
>> They get highlighted with `font-lock-variable-use-face` at level 4, but shouldn't
>> they be getting `font-lock-variable-name-face` in the 'definition feature?
>>
>
> Indeed, thanks. Could someone please install the patch? Thanks in advance.
Now pushed to master. Thanks Noah!
> Seems like c++-ts-mode will need to get updated too, as with:
> for (const auto& i : things) {}
> i gets font-lock-variable-use-face. I wonder if any other ts modes
> have similar issues.
I would probably rather call those "missing features" rather than
issues. I've added such highlightings to some of the constructs for
several treesit modes last year, but more can be missing, so
contributions welcome.
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:56 ` Noah Peart
@ 2024-06-01 1:59 ` Dmitry Gutov
2024-06-01 2:04 ` Noah Peart
0 siblings, 1 reply; 20+ messages in thread
From: Dmitry Gutov @ 2024-06-01 1:59 UTC (permalink / raw)
To: Noah Peart; +Cc: 71209, Randy Taylor
On 01/06/2024 04:56, Noah Peart wrote:
> > Only if you set treesit-font-lock-level to 4, right?
>
> Yea, that's true - I assumed most people(?) do, but I just realized
> I hadn't been doing that for years until tree-sitter - and now I've
> become obsessive compulsive about my fonts.
I imagine most actual users just keep in on the default value. But a lot
customize it, of course, to get closer to "VS Code look".
Personally, I stay with the default, among other things because most of
the level 4 'variable' highlights just take the easy route and highlight
all the tokens that haven't been matched by any other existing rule.
That doesn't feel useful to me.
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:59 ` Dmitry Gutov
@ 2024-06-01 2:04 ` Noah Peart
0 siblings, 0 replies; 20+ messages in thread
From: Noah Peart @ 2024-06-01 2:04 UTC (permalink / raw)
To: Dmitry Gutov; +Cc: 71209, Randy Taylor
[-- Attachment #1: Type: text/plain, Size: 1281 bytes --]
> Personally, I stay with the default, among other things because most of
> the level 4 'variable' highlights just take the easy route and highlight
> all the tokens that haven't been matched by any other existing rule.
> That doesn't feel useful to me.
I agree, I used level 4 with the use-face and name-faces being the same
for while, but have since changed use-faces to be only a shade different
from the default face. It's way more informative to have the decls solidly
stand out.
On Fri, May 31, 2024 at 6:59 PM Dmitry Gutov <dmitry@gutov.dev> wrote:
> On 01/06/2024 04:56, Noah Peart wrote:
> > > Only if you set treesit-font-lock-level to 4, right?
> >
> > Yea, that's true - I assumed most people(?) do, but I just realized
> > I hadn't been doing that for years until tree-sitter - and now I've
> > become obsessive compulsive about my fonts.
>
> I imagine most actual users just keep in on the default value. But a lot
> customize it, of course, to get closer to "VS Code look".
>
> Personally, I stay with the default, among other things because most of
> the level 4 'variable' highlights just take the easy route and highlight
> all the tokens that haven't been matched by any other existing rule.
> That doesn't feel useful to me.
>
[-- Attachment #2: Type: text/html, Size: 1791 bytes --]
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:50 ` Noah Peart
@ 2024-06-01 14:13 ` Dmitry Gutov
0 siblings, 0 replies; 20+ messages in thread
From: Dmitry Gutov @ 2024-06-01 14:13 UTC (permalink / raw)
To: Noah Peart, Randy Taylor; +Cc: 71209
On 01/06/2024 04:50, Noah Peart wrote:
> There is a similar issue with font-lock-property-name-face
> and font-lock-property-use-face. I've noticed different modes
> treat things differently. I think object fields in literals should get
> property-name-face, but json-ts-mode, for example,
> doesn't use font-lock-property-name-face at all.
Yeah, that sounds about right. Probably needs some formalization,
because for cases like json and html I wasn't 100% sure which semantics
to choose, and unlike in programming code this didn't seem urgent at the
time.
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 1:42 ` Noah Peart
2024-06-01 1:50 ` Noah Peart
2024-06-01 1:51 ` Dmitry Gutov
@ 2024-06-01 14:13 ` Dmitry Gutov
2024-06-15 7:56 ` Eli Zaretskii
2 siblings, 1 reply; 20+ messages in thread
From: Dmitry Gutov @ 2024-06-01 14:13 UTC (permalink / raw)
To: Noah Peart, Randy Taylor; +Cc: 71209
On 01/06/2024 04:42, Noah Peart wrote:
>
> I've been using these for c++, I think they are still missing
>
> ;; for (auto x: ...)
> (for_range_loop
> declarator: (identifier) @font-lock-variable-name-face)
> ;; auto& x
> (reference_declarator
> (identifier) @font-lock-variable-name-face)
> ;; auto[&] [x, y]
> (structured_binding_declarator
> _ [(identifier)] @font-lock-variable-name-face)
>
> I suppose most people keep the default font-locking for variable-name
> and variable-use, so these missing rules go unnoticed.
Do you want to submit a full patch with these as well?
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-01 14:13 ` Dmitry Gutov
@ 2024-06-15 7:56 ` Eli Zaretskii
2024-06-27 7:38 ` Eli Zaretskii
0 siblings, 1 reply; 20+ messages in thread
From: Eli Zaretskii @ 2024-06-15 7:56 UTC (permalink / raw)
To: noah.v.peart, Dmitry Gutov; +Cc: 71209, dev
Ping! Noah, would you please answer Dmitry?
> Cc: 71209@debbugs.gnu.org
> Date: Sat, 1 Jun 2024 17:13:57 +0300
> From: Dmitry Gutov <dmitry@gutov.dev>
>
> On 01/06/2024 04:42, Noah Peart wrote:
> >
> > I've been using these for c++, I think they are still missing
> >
> > ;; for (auto x: ...)
> > (for_range_loop
> > declarator: (identifier) @font-lock-variable-name-face)
> > ;; auto& x
> > (reference_declarator
> > (identifier) @font-lock-variable-name-face)
> > ;; auto[&] [x, y]
> > (structured_binding_declarator
> > _ [(identifier)] @font-lock-variable-name-face)
> >
> > I suppose most people keep the default font-locking for variable-name
> > and variable-use, so these missing rules go unnoticed.
>
> Do you want to submit a full patch with these as well?
>
>
>
>
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-15 7:56 ` Eli Zaretskii
@ 2024-06-27 7:38 ` Eli Zaretskii
2024-06-27 9:29 ` Noah Peart
0 siblings, 1 reply; 20+ messages in thread
From: Eli Zaretskii @ 2024-06-27 7:38 UTC (permalink / raw)
To: noah.v.peart; +Cc: 71209, dmitry, dev
Ping! Ping! Noah, are you still interested in working on this?
> Cc: 71209@debbugs.gnu.org, dev@rjt.dev
> Date: Sat, 15 Jun 2024 10:56:36 +0300
> From: Eli Zaretskii <eliz@gnu.org>
>
> Ping! Noah, would you please answer Dmitry?
>
> > Cc: 71209@debbugs.gnu.org
> > Date: Sat, 1 Jun 2024 17:13:57 +0300
> > From: Dmitry Gutov <dmitry@gutov.dev>
> >
> > On 01/06/2024 04:42, Noah Peart wrote:
> > >
> > > I've been using these for c++, I think they are still missing
> > >
> > > ;; for (auto x: ...)
> > > (for_range_loop
> > > declarator: (identifier) @font-lock-variable-name-face)
> > > ;; auto& x
> > > (reference_declarator
> > > (identifier) @font-lock-variable-name-face)
> > > ;; auto[&] [x, y]
> > > (structured_binding_declarator
> > > _ [(identifier)] @font-lock-variable-name-face)
> > >
> > > I suppose most people keep the default font-locking for variable-name
> > > and variable-use, so these missing rules go unnoticed.
> >
> > Do you want to submit a full patch with these as well?
> >
> >
> >
> >
>
>
>
>
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-27 7:38 ` Eli Zaretskii
@ 2024-06-27 9:29 ` Noah Peart
2024-07-06 7:46 ` Eli Zaretskii
0 siblings, 1 reply; 20+ messages in thread
From: Noah Peart @ 2024-06-27 9:29 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: 71209, dmitry, dev
[-- Attachment #1: Type: text/plain, Size: 1358 bytes --]
Ah yes, sorry to be slow, I can submit a patch for those settings. I'll
take a look today!
On Thu, Jun 27, 2024 at 3:38 AM Eli Zaretskii <eliz@gnu.org> wrote:
> Ping! Ping! Noah, are you still interested in working on this?
>
> > Cc: 71209@debbugs.gnu.org, dev@rjt.dev
> > Date: Sat, 15 Jun 2024 10:56:36 +0300
> > From: Eli Zaretskii <eliz@gnu.org>
> >
> > Ping! Noah, would you please answer Dmitry?
> >
> > > Cc: 71209@debbugs.gnu.org
> > > Date: Sat, 1 Jun 2024 17:13:57 +0300
> > > From: Dmitry Gutov <dmitry@gutov.dev>
> > >
> > > On 01/06/2024 04:42, Noah Peart wrote:
> > > >
> > > > I've been using these for c++, I think they are still missing
> > > >
> > > > ;; for (auto x: ...)
> > > > (for_range_loop
> > > > declarator: (identifier) @font-lock-variable-name-face)
> > > > ;; auto& x
> > > > (reference_declarator
> > > > (identifier) @font-lock-variable-name-face)
> > > > ;; auto[&] [x, y]
> > > > (structured_binding_declarator
> > > > _ [(identifier)] @font-lock-variable-name-face)
> > > >
> > > > I suppose most people keep the default font-locking for variable-name
> > > > and variable-use, so these missing rules go unnoticed.
> > >
> > > Do you want to submit a full patch with these as well?
> > >
> > >
> > >
> > >
> >
> >
> >
> >
>
[-- Attachment #2: Type: text/html, Size: 2278 bytes --]
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-06-27 9:29 ` Noah Peart
@ 2024-07-06 7:46 ` Eli Zaretskii
2024-07-20 9:42 ` Eli Zaretskii
0 siblings, 1 reply; 20+ messages in thread
From: Eli Zaretskii @ 2024-07-06 7:46 UTC (permalink / raw)
To: Noah Peart; +Cc: 71209, dmitry, dev
Ping! Any progress with this?
> From: Noah Peart <noah.v.peart@gmail.com>
> Date: Thu, 27 Jun 2024 05:29:21 -0400
> Cc: dmitry@gutov.dev, 71209@debbugs.gnu.org, dev@rjt.dev
>
> Ah yes, sorry to be slow, I can submit a patch for those settings. I'll take a look today!
>
> On Thu, Jun 27, 2024 at 3:38 AM Eli Zaretskii <eliz@gnu.org> wrote:
>
> Ping! Ping! Noah, are you still interested in working on this?
>
> > Cc: 71209@debbugs.gnu.org, dev@rjt.dev
> > Date: Sat, 15 Jun 2024 10:56:36 +0300
> > From: Eli Zaretskii <eliz@gnu.org>
> >
> > Ping! Noah, would you please answer Dmitry?
> >
> > > Cc: 71209@debbugs.gnu.org
> > > Date: Sat, 1 Jun 2024 17:13:57 +0300
> > > From: Dmitry Gutov <dmitry@gutov.dev>
> > >
> > > On 01/06/2024 04:42, Noah Peart wrote:
> > > >
> > > > I've been using these for c++, I think they are still missing
> > > >
> > > > ;; for (auto x: ...)
> > > > (for_range_loop
> > > > declarator: (identifier) @font-lock-variable-name-face)
> > > > ;; auto& x
> > > > (reference_declarator
> > > > (identifier) @font-lock-variable-name-face)
> > > > ;; auto[&] [x, y]
> > > > (structured_binding_declarator
> > > > _ [(identifier)] @font-lock-variable-name-face)
> > > >
> > > > I suppose most people keep the default font-locking for variable-name
> > > > and variable-use, so these missing rules go unnoticed.
> > >
> > > Do you want to submit a full patch with these as well?
> > >
> > >
> > >
> > >
> >
> >
> >
> >
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-07-06 7:46 ` Eli Zaretskii
@ 2024-07-20 9:42 ` Eli Zaretskii
2024-08-04 7:52 ` Eli Zaretskii
0 siblings, 1 reply; 20+ messages in thread
From: Eli Zaretskii @ 2024-07-20 9:42 UTC (permalink / raw)
To: noah.v.peart; +Cc: 71209, dmitry, dev
Ping! Ping! Can we please make some progress here?
> Cc: 71209@debbugs.gnu.org, dmitry@gutov.dev, dev@rjt.dev
> Date: Sat, 06 Jul 2024 10:46:44 +0300
> From: Eli Zaretskii <eliz@gnu.org>
>
> Ping! Any progress with this?
>
> > From: Noah Peart <noah.v.peart@gmail.com>
> > Date: Thu, 27 Jun 2024 05:29:21 -0400
> > Cc: dmitry@gutov.dev, 71209@debbugs.gnu.org, dev@rjt.dev
> >
> > Ah yes, sorry to be slow, I can submit a patch for those settings. I'll take a look today!
> >
> > On Thu, Jun 27, 2024 at 3:38 AM Eli Zaretskii <eliz@gnu.org> wrote:
> >
> > Ping! Ping! Noah, are you still interested in working on this?
> >
> > > Cc: 71209@debbugs.gnu.org, dev@rjt.dev
> > > Date: Sat, 15 Jun 2024 10:56:36 +0300
> > > From: Eli Zaretskii <eliz@gnu.org>
> > >
> > > Ping! Noah, would you please answer Dmitry?
> > >
> > > > Cc: 71209@debbugs.gnu.org
> > > > Date: Sat, 1 Jun 2024 17:13:57 +0300
> > > > From: Dmitry Gutov <dmitry@gutov.dev>
> > > >
> > > > On 01/06/2024 04:42, Noah Peart wrote:
> > > > >
> > > > > I've been using these for c++, I think they are still missing
> > > > >
> > > > > ;; for (auto x: ...)
> > > > > (for_range_loop
> > > > > declarator: (identifier) @font-lock-variable-name-face)
> > > > > ;; auto& x
> > > > > (reference_declarator
> > > > > (identifier) @font-lock-variable-name-face)
> > > > > ;; auto[&] [x, y]
> > > > > (structured_binding_declarator
> > > > > _ [(identifier)] @font-lock-variable-name-face)
> > > > >
> > > > > I suppose most people keep the default font-locking for variable-name
> > > > > and variable-use, so these missing rules go unnoticed.
> > > >
> > > > Do you want to submit a full patch with these as well?
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> > >
> > >
>
>
>
>
^ permalink raw reply [flat|nested] 20+ messages in thread
* bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses
2024-07-20 9:42 ` Eli Zaretskii
@ 2024-08-04 7:52 ` Eli Zaretskii
0 siblings, 0 replies; 20+ messages in thread
From: Eli Zaretskii @ 2024-08-04 7:52 UTC (permalink / raw)
To: noah.v.peart; +Cc: 71209, dmitry, dev
Ping! Ping! Ping! Noah, are you there?
> Cc: 71209@debbugs.gnu.org, dmitry@gutov.dev, dev@rjt.dev
> Date: Sat, 20 Jul 2024 12:42:00 +0300
> From: Eli Zaretskii <eliz@gnu.org>
>
> Ping! Ping! Can we please make some progress here?
>
> > Cc: 71209@debbugs.gnu.org, dmitry@gutov.dev, dev@rjt.dev
> > Date: Sat, 06 Jul 2024 10:46:44 +0300
> > From: Eli Zaretskii <eliz@gnu.org>
> >
> > Ping! Any progress with this?
> >
> > > From: Noah Peart <noah.v.peart@gmail.com>
> > > Date: Thu, 27 Jun 2024 05:29:21 -0400
> > > Cc: dmitry@gutov.dev, 71209@debbugs.gnu.org, dev@rjt.dev
> > >
> > > Ah yes, sorry to be slow, I can submit a patch for those settings. I'll take a look today!
> > >
> > > On Thu, Jun 27, 2024 at 3:38 AM Eli Zaretskii <eliz@gnu.org> wrote:
> > >
> > > Ping! Ping! Noah, are you still interested in working on this?
> > >
> > > > Cc: 71209@debbugs.gnu.org, dev@rjt.dev
> > > > Date: Sat, 15 Jun 2024 10:56:36 +0300
> > > > From: Eli Zaretskii <eliz@gnu.org>
> > > >
> > > > Ping! Noah, would you please answer Dmitry?
> > > >
> > > > > Cc: 71209@debbugs.gnu.org
> > > > > Date: Sat, 1 Jun 2024 17:13:57 +0300
> > > > > From: Dmitry Gutov <dmitry@gutov.dev>
> > > > >
> > > > > On 01/06/2024 04:42, Noah Peart wrote:
> > > > > >
> > > > > > I've been using these for c++, I think they are still missing
> > > > > >
> > > > > > ;; for (auto x: ...)
> > > > > > (for_range_loop
> > > > > > declarator: (identifier) @font-lock-variable-name-face)
> > > > > > ;; auto& x
> > > > > > (reference_declarator
> > > > > > (identifier) @font-lock-variable-name-face)
> > > > > > ;; auto[&] [x, y]
> > > > > > (structured_binding_declarator
> > > > > > _ [(identifier)] @font-lock-variable-name-face)
> > > > > >
> > > > > > I suppose most people keep the default font-locking for variable-name
> > > > > > and variable-use, so these missing rules go unnoticed.
> > > > >
> > > > > Do you want to submit a full patch with these as well?
> > > > >
> > > > >
> > > > >
> > > > >
> > > >
> > > >
> > > >
> > > >
> >
> >
> >
> >
>
>
>
>
^ permalink raw reply [flat|nested] 20+ messages in thread
end of thread, other threads:[~2024-08-04 7:52 UTC | newest]
Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-26 12:41 bug#71209: [PATCH] Add font-locking for variables in go-ts-mode range clauses Noah Peart
2024-05-28 2:46 ` Randy Taylor
2024-05-30 13:25 ` Noah Peart
2024-05-30 23:23 ` Dmitry Gutov
2024-06-01 1:09 ` Randy Taylor
2024-06-01 1:42 ` Noah Peart
2024-06-01 1:50 ` Noah Peart
2024-06-01 14:13 ` Dmitry Gutov
2024-06-01 1:51 ` Dmitry Gutov
2024-06-01 1:56 ` Noah Peart
2024-06-01 1:59 ` Dmitry Gutov
2024-06-01 2:04 ` Noah Peart
2024-06-01 14:13 ` Dmitry Gutov
2024-06-15 7:56 ` Eli Zaretskii
2024-06-27 7:38 ` Eli Zaretskii
2024-06-27 9:29 ` Noah Peart
2024-07-06 7:46 ` Eli Zaretskii
2024-07-20 9:42 ` Eli Zaretskii
2024-08-04 7:52 ` Eli Zaretskii
2024-06-01 1:56 ` Dmitry Gutov
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.