Files
wire/internal/goose/testdata/ImportedInterfaceBinding/bar/bar.go
Ross Light f8e446fa17 goose: use marker functions instead of comments
To avoid making this CL too large, I did not migrate the existing goose
comments through the repository.  This will be addressed in a subsequent
CL.

Reviewed-by: Tuo Shan <shantuo@google.com>
2018-11-12 14:09:56 -08:00

29 lines
332 B
Go

package main
import (
"fmt"
"codename/goose"
"foo"
)
func main() {
fmt.Println(injectFooer().Foo())
}
type Bar string
func (b *Bar) Foo() string {
return string(*b)
}
func provideBar() *Bar {
b := new(Bar)
*b = "Hello, World!"
return b
}
var Set = goose.NewSet(
provideBar,
goose.Bind(foo.Fooer(nil), (*Bar)(nil)))