treewalker.nvim
treewalker.nvim copied to clipboard
Treewalker seems to to not be able walk upwards inside nested blocks in .go files
https://github.com/user-attachments/assets/ecb57beb-f81f-4423-b6c4-15f0b5981361
Code to reproduce:
package main
import (
"bufio"
"fmt"
"os"
"strings"
)
func ScannerExample() {
// scanner is a handy way to work with files, mainly for its tokenization way,
// its used for read by lines or read by words but has other options too.
// its not as efficient as buffio.reader/writer but nicer way for simple and easy things.
scanner := bufio.NewScanner(os.Stdin)
// return false if end of the input or error
for scanner.Scan() {
ucl := strings.ToUpper(scanner.Text())
fmt.Println(ucl)
}
if err := scanner.Err(); err != nil {
fmt.Fprintln(os.Stderr, "error:", err)
os.Exit(1)
}
}
I can't reproduce this on the commit you made it on, but after the recent commit closing #66, the selection criteria changed slightly, so maybe see if you can revalidate this on latest
Okay, this is fixed, but the switch/case is broken in another way, i will continue here: #66