Debian Codegraph @

gopls/internal/test/marker/testdata/references/issue76872.txt

raw
1 This test exercises a references query at a position where an empty selection
2 might be considered enclosed both by the node before (Ident) and the node after
3 (FuncType). It ensures that we find the reference of the syntax node before the
4 cursor.
5
6 See https://github.com/golang/go/issues/76872.
7
8 -- main.go --
9 package main
10
11 // re"foo()" matches the zero-width position after "foo", not the call parens.
12 func foo() {} //@ loc(decl, "foo"), refs(re"foo()", decl, call)
13
14 func _() {
15 foo() //@ loc(call, "foo")
16 }