github.com/bananabytelabs/wazero@v0.0.0-20240105073314-54b22a776da8/internal/close/close.go (about)

     1  // Package close allows experimental.CloseNotifier without introducing a
     2  // package cycle.
     3  package close
     4  
     5  import "context"
     6  
     7  // NotifierKey is a context.Context Value key. Its associated value should be a
     8  // Notifier.
     9  type NotifierKey struct{}
    10  
    11  type Notifier interface {
    12  	CloseNotify(ctx context.Context, exitCode uint32)
    13  }