diff options
Diffstat (limited to 'structs.go')
| -rw-r--r-- | structs.go | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -160,8 +160,9 @@ func (w *guiWidget) Write(p []byte) (n int, err error) { return len(p), nil } -// this sets the `default` in the structs -// this is cool code. thank Alex Flint & other GO devs for this code +// THIS IS GO COMPILER MAGIC +// this sets the `default` in the structs above on init() +// this is cool code. thank the GO devs for this code and Alex Flint for explaining it to me func Set(ptr interface{}, tag string) error { if reflect.TypeOf(ptr).Kind() != reflect.Ptr { log.Log(ERROR, "Set() Not a pointer", ptr, "with tag =", tag) |
