bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#61006: 29.0.60; Wrong indentation in go-ts-mode


From: Randy Taylor
Subject: bug#61006: 29.0.60; Wrong indentation in go-ts-mode
Date: Wed, 25 Jan 2023 02:35:20 +0000

On Sunday, January 22nd, 2023 at 05:00, sskostyaev@gmail.com 
<sskostyaev@gmail.com> wrote:
> 
> Hi. Thank you all for great work.
> In go-ts-mode indentation breaks in function or method definition if
> arguments placed on separate lines like this:
> `func transform( s string, ) string {`
> This code should be indented like this:
> `func transform( s string, ) string {`

Thanks for the report. I've attached a patch that fixes this.

> Also `go-ts-mode-indent-offset' should be 8 by default. In go world there is 
> gofmt which is a real standart for code indentation. It would be great if 
> emacs will provide the same indentation out of the box.

And addresses this.

> There is also other issue - sometimes go-ts-mode syntax highliting breaks 
> when I actively use it with` lsp-mode`- refactorings, auto formatting etc. 
> But I can't reproduce it with`eglot`.

Seems like an `lsp-mode` problem then? I only use `eglot` and haven't noticed 
anything amiss.

Attachment: 0001-Fix-go-ts-mode-parameter-indentation-and-set-indent-.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]