Giant blob of minor changes
[dotfiles/.git] / .config / coc / extensions / coc-go-data / tools / pkg / mod / golang.org / x / tools@v0.0.0-20201028153306-37f0764111ff / internal / lsp / testdata / godef / a / random.go
1 package a
2
3 func Random() int { //@Random
4         y := 6 + 7
5         return y
6 }
7
8 func Random2(y int) int { //@Random2,mark(RandomParamY, "y")
9         return y //@godef("y", RandomParamY)
10 }
11
12 type Pos struct {
13         x, y int //@mark(PosX, "x"),mark(PosY, "y")
14 }
15
16 // Typ has a comment. Its fields do not.
17 type Typ struct{ field string } //@mark(TypField, "field")
18
19 func _() {
20         x := &Typ{}
21         x.field //@godef("field", TypField)
22 }
23
24 func (p *Pos) Sum() int { //@mark(PosSum, "Sum")
25         return p.x + p.y //@godef("x", PosX)
26 }
27
28 func _() {
29         var p Pos
30         _ = p.Sum() //@godef("()", PosSum)
31 }