aboutsummaryrefslogtreecommitdiff
path: root/gopls/internal/lsp/testdata/extract/extract_function/extract_return_func_lit.go
diff options
context:
space:
mode:
Diffstat (limited to 'gopls/internal/lsp/testdata/extract/extract_function/extract_return_func_lit.go')
-rw-r--r--gopls/internal/lsp/testdata/extract/extract_function/extract_return_func_lit.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/gopls/internal/lsp/testdata/extract/extract_function/extract_return_func_lit.go b/gopls/internal/lsp/testdata/extract/extract_function/extract_return_func_lit.go
new file mode 100644
index 000000000..b3fb4fd21
--- /dev/null
+++ b/gopls/internal/lsp/testdata/extract/extract_function/extract_return_func_lit.go
@@ -0,0 +1,13 @@
+package extract
+
+import "go/ast"
+
+func _() {
+ ast.Inspect(ast.NewIdent("a"), func(n ast.Node) bool {
+ if n == nil { //@mark(exSt4, "if")
+ return true
+ } //@mark(exEn4, "}")
+ return false
+ })
+ //@extractfunc(exSt4, exEn4)
+}