blob: 9c81cad31718c2f8d7e6248c0639d9406b7e5d4d [file] [log] [blame]
package b
import (
"fmt"
"golang.org/lsptests/godef/a"
)
func useThings() {
t := a.Thing{} //@mark(bStructType, "ing")
fmt.Print(t.Member) //@mark(bMember, "ember")
fmt.Print(a.Other) //@mark(bVar, "ther")
a.Things() //@mark(bFunc, "ings")
}
/*@
godef(bStructType, Thing)
godef(bMember, Member)
godef(bVar, Other)
godef(bFunc, Things)
*/
func _() {
var x interface{} //@mark(eInterface, "interface{}")
switch x := x.(type) { //@hoverdef("x", eInterface)
case string: //@mark(eString, "string")
fmt.Println(x) //@hoverdef("x", eString)
case int: //@mark(eInt, "int")
fmt.Println(x) //@hoverdef("x", eInt)
}
}