github.com/gmemcc/yaegi@v0.12.1-0.20221128122509-aa99124c5d16/_test/method38/a.go (about)

     1  package method38
     2  
     3  import "sync"
     4  
     5  func NewPool() Pool { return Pool{} }
     6  
     7  type Buffer struct {
     8  	bs   []byte
     9  	pool Pool
    10  }
    11  
    12  type Pool struct {
    13  	p *sync.Pool
    14  }
    15  
    16  var (
    17  	_pool = NewPool()
    18  	Get   = _pool.Get
    19  )