github.com/gagliardetto/golang-go@v0.0.0-20201020153340-53909ea70814/cmd/compile/internal/ssa/testdata/infloop.go (about)

     1  package main
     2  
     3  var sink int
     4  
     5  //go:noinline
     6  func test() {
     7  	// This is for #30167, incorrect line numbers in an infinite loop
     8  	go func() {}()
     9  
    10  	for {
    11  	}
    12  }
    13  
    14  func main() {
    15  	test()
    16  }