NewLatch creates a new Latch.
()
| 12 | |
| 13 | // NewLatch creates a new Latch. |
| 14 | func NewLatch() *Latch { |
| 15 | return &Latch{done: make(chan struct{})} |
| 16 | } |
| 17 | |
| 18 | // Release releases the latch, allowing all waiting goroutines to proceed. |
| 19 | func (g *Latch) Release() { |
no outgoing calls