Subject: bug#60025: [PATCH] Add go-ts-mode and go-mod-ts-mode

From: Theodor Thornhill <[email-masked]>
Date: Thu, 15 Dec 2022 19:06:13 +0100

On 15 December 2022 17:40:54 CET, Randy Taylor <[email-masked]> wrote:
>On Thursday, December 15th, 2022 at 02:20, Theodor Thornhill <[email-masked]> wrote:
>> 
>> Randy Taylor [email-masked] writes:
>>
>> > 
>> > Thanks Theo, that worked perfectly. We should consider adding
>> > something like this to the documentation somewhere, since I didn't see
>> > anything like this anywhere (although maybe I missed it).
>> 
>> 
>> I'm glad! Could be part of a tips and tricks or something?
>
>I think it should probably be part of whatever indentation documentation there is.
>
>> 
>> No rules for comment?
>> 
>> [...]
>>
>> No rules for comment here either?
>
>Which rules should I add?
>

I like to set no-indent in a comment so that indentation commands don't format. That should be fillings job, imo :)

>I see these rules in some of the ts modes:
>((and (parent-is "comment") comment-end) comment-start -1)
>((parent-is "comment") comment-start-skip 0)
>
>What are they matching? When could a comment be a parent?

In some languages comment has a parent which is a comment. Just use inspect-mode inside of a comment and see what makes sense :)

>
>(BTW attached a new patch with an updated NEWS entry after the recent changes there).