Giant blob of minor changes
[dotfiles/.git] / .config / coc / extensions / coc-go-data / tools / pkg / mod / golang.org / x / tools@v0.0.0-20201105173854-bc9fc8d8c4bc / cmd / guru / testdata / src / calls-json / main.go
diff --git a/.config/coc/extensions/coc-go-data/tools/pkg/mod/golang.org/x/tools@v0.0.0-20201105173854-bc9fc8d8c4bc/cmd/guru/testdata/src/calls-json/main.go b/.config/coc/extensions/coc-go-data/tools/pkg/mod/golang.org/x/tools@v0.0.0-20201105173854-bc9fc8d8c4bc/cmd/guru/testdata/src/calls-json/main.go
new file mode 100644 (file)
index 0000000..9d58ed1
--- /dev/null
@@ -0,0 +1,16 @@
+package main
+
+// Tests of call-graph queries, -format=json.
+// See go.tools/guru/guru_test.go for explanation.
+// See calls-json.golden for expected query results.
+
+func call(f func()) {
+       f() // @callees @callees-f "f"
+}
+
+func main() {
+       call(func() {
+               // @callers callers-main.anon "^"
+               // @callstack callstack-main.anon "^"
+       })
+}