Subject: bug#78130: Acknowledgement ([PATCH] 31.0.50; csharp-ts-mode does not highlight generic types correctly everywhere)

From: Jostein Kjønigsen <[email-masked]>
Date: Tue, 29 Apr 2025 21:51:54 +0200

Attached is a better patch, which addresses a lot of different areas of C# fontification.

Overall I think these are pure improvements:

- fontification of generic types with namespace-prefixes
- function-call parameters
- variable use in string interpolation
- implicitly typed parameters in lambda-expressions
- index-expressions
- variables used in return-statements
- variables used in binary expressions

What might warrant some review is the use of the (:match) selector to identify local variables (as opposed to properties or types) for a more consistent fontification. This is the first time I'm using it, and I see there's some repetition in the implementation... Could this be improved somehow?

Do we have a "emacsy" way or convention to do this which I could have applied, or is it still a bit early wrt treesitter based modes?

￼

—
Kind Regards
Jostein Kjønigsen

> On 29 Apr 2025, at 13:13, Jostein Kjønigsen <[email-masked]> wrote:
> 
> Just a FYI: I've uncovered some use-cases which my patch does not address correctly: namely function invocations.
> 
> The bug is still real, but I'll be restructuring my fix and submitting when I think I have something which works better.
> 
> —
> Kind Regards
> Jostein Kjønigsen
> 
>> On 29 Apr 2025, at 11:53, GNU bug Tracking System <[email-masked]> wrote:
>> 
>> Thank you for filing a new bug report with debbugs.gnu.org.
>> 
>> This is an automatically generated reply to let you know your message
>> has been received.
>> 
>> Your message is being forwarded to the package maintainers and other
>> interested parties for their attention; they will reply in due course.
>> 
>> Your message has been sent to the package maintainer(s):
>> [email-masked]
>> 
>> If you wish to submit further information on this problem, please
>> send it to [email-masked].
>> 
>> Please do not send mail to [email-masked] unless you wish
>> to report a problem with the Bug-tracking system.
>> 
>> -- 
>> 78130: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=78130
>> GNU Bug Tracking System
>> Contact [email-masked] with problems
>