23 lines
315 B
Go
23 lines
315 B
Go
|
|
package main
|
||
|
|
|
||
|
|
import (
|
||
|
|
stdcontext "context"
|
||
|
|
"fmt"
|
||
|
|
"os"
|
||
|
|
)
|
||
|
|
|
||
|
|
type context struct{}
|
||
|
|
|
||
|
|
func main() {
|
||
|
|
c, err := inject(stdcontext.Background(), struct{}{})
|
||
|
|
if err != nil {
|
||
|
|
fmt.Println("ERROR:", err)
|
||
|
|
os.Exit(1)
|
||
|
|
}
|
||
|
|
fmt.Println(c)
|
||
|
|
}
|
||
|
|
|
||
|
|
func provide(ctx stdcontext.Context) (context, error) {
|
||
|
|
return context{}, nil
|
||
|
|
}
|