github.com/amarpal/go-tools@v0.0.0-20240422043104-40142f59f616/simple/s1005/testdata/src/example.com/CheckUnnecessaryBlank/LintBlankOK.go (about)

     1  package pkg
     2  
     3  func fn() {
     4  	var m map[int]int
     5  	var ch chan int
     6  	var fn func() (int, bool)
     7  
     8  	x, _ := m[0] //@ diag(`unnecessary assignment to the blank identifier`)
     9  	x, _ = <-ch  //@ diag(`unnecessary assignment to the blank identifier`)
    10  	x, _ = fn()
    11  	_ = x
    12  }