(ctx context.Context, fn EnvironFn)
| 11 | type EnvironFn func() []string |
| 12 | |
| 13 | func WithEnvironFn(ctx context.Context, fn EnvironFn) context.Context { |
| 14 | return context.WithValue(ctx, environKey{}, fn) |
| 15 | } |
| 16 | |
| 17 | func Environ(ctx context.Context) []string { |
| 18 | fn := ctx.Value(environKey{}) |
no outgoing calls