mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-13 00:40:06 -04:00
indents(go): perform some changes as go fmt dictates
This commit is contained in:
parent
0d1c1efff5
commit
9f25d66f7d
2 changed files with 9 additions and 4 deletions
|
|
@ -9,15 +9,15 @@
|
||||||
(expression_case)
|
(expression_case)
|
||||||
(default_case)
|
(default_case)
|
||||||
(block)
|
(block)
|
||||||
|
(call_expression)
|
||||||
|
(parameter_list)
|
||||||
] @indent
|
] @indent
|
||||||
|
|
||||||
[
|
[
|
||||||
"case"
|
"case"
|
||||||
")"
|
|
||||||
"}"
|
"}"
|
||||||
] @branch
|
] @branch
|
||||||
|
|
||||||
(comment) @ignore
|
(parameter_list ")" @branch)
|
||||||
|
|
||||||
([(parameter_list)] @aligned_indent
|
(comment) @ignore
|
||||||
(#set! "delimiter" "()"))
|
|
||||||
|
|
|
||||||
|
|
@ -11,4 +11,9 @@ func badIndent(
|
||||||
param string, // this is the difference
|
param string, // this is the difference
|
||||||
) {
|
) {
|
||||||
fmt.Println("typing o here triggers bad indent")
|
fmt.Println("typing o here triggers bad indent")
|
||||||
|
foo(bar,
|
||||||
|
baz,
|
||||||
|
call,
|
||||||
|
stop,
|
||||||
|
please)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue