Created
February 9, 2023 21:20
-
-
Save brurucy/fadbc59a284bcd78eccf0fac441871a4 to your computer and use it in GitHub Desktop.
memoir
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Option func(*Obj) | |
func Foo(foo int) Option { | |
return func(obj *Obj) { | |
obj.foo = foo | |
} | |
} | |
func Bar(bar string) Option { | |
return func(obj *Obj) { | |
obj.bar = bar | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment