github.com/jhump/golang-x-tools@v0.0.0-20220218190644-4958d6d39439/internal/lsp/testdata/maps/maps.go.in (about)

     1  package maps
     2  
     3  func _() {
     4  	var aVar int          //@item(mapVar, "aVar", "int", "var")
     5  
     6  	// not comparabale
     7  	type aSlice []int     //@item(mapSliceType, "aSlice", "[]int", "type")
     8  
     9  	*aSlice     //@item(mapSliceTypePtr, "*aSlice", "[]int", "type")
    10  
    11  	// comparable
    12  	type aStruct struct{} //@item(mapStructType, "aStruct", "struct{...}", "struct")
    13  
    14  	map[]a{} //@complete("]", mapSliceType, mapStructType),snippet("]", mapSliceType, "*aSlice", "*aSlice")
    15  
    16  	map[a]a{} //@complete("]", mapSliceType, mapStructType)
    17  	map[a]a{} //@complete("{", mapSliceType, mapStructType)
    18  }