Run code through gofmt.
This commit is contained in:
parent
f980a9f931
commit
b1f8c9d7a7
1 changed files with 6 additions and 6 deletions
12
struct.go
12
struct.go
|
@ -279,12 +279,12 @@ func (b *structBuilder) Key(k string) Builder {
|
||||||
//
|
//
|
||||||
|
|
||||||
func Unmarshal(r io.Reader, val interface{}) (err os.Error) {
|
func Unmarshal(r io.Reader, val interface{}) (err os.Error) {
|
||||||
// If e represents a value, the answer won't get back to the
|
// If e represents a value, the answer won't get back to the
|
||||||
// caller. Make sure it's a pointer.
|
// caller. Make sure it's a pointer.
|
||||||
if _, ok := reflect.Typeof(val).(*reflect.PtrType); !ok {
|
if _, ok := reflect.Typeof(val).(*reflect.PtrType); !ok {
|
||||||
err = os.ErrorString("Attempt to unmarshal into a non-pointer")
|
err = os.ErrorString("Attempt to unmarshal into a non-pointer")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
err = UnmarshalValue(r, reflect.NewValue(val))
|
err = UnmarshalValue(r, reflect.NewValue(val))
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue