github.com/machinefi/w3bstream@v1.6.5-rc9.0.20240426031326-b8c7c4876e72/pkg/depends/x/pkgx/__tests__/sub/call.go (about)

     1  package sub
     2  
     3  func v() int {
     4  	return 2
     5  }
     6  
     7  func call() func() int {
     8  	return v
     9  }
    10  
    11  type Func func() func() int
    12  
    13  func CurryCall() Func {
    14  	if true {
    15  		return func() func() int {
    16  			return func() int {
    17  				return 1
    18  			}
    19  		}
    20  	}
    21  	return func() func() int {
    22  		return call()
    23  	}
    24  }