MCPcopy Create free account
hub / github.com/aws/smithy-go / decodeBool

Method decodeBool

document/cbor/decode.go:126–134  ·  view source on GitHub ↗
(v bool, rv reflect.Value)

Source from the content-addressed store, hash-verified

124}
125
126func (d *decoder) decodeBool(v bool, rv reflect.Value) error {
127 switch rv.Kind() {
128 case reflect.Bool, reflect.Interface:
129 rv.Set(reflect.ValueOf(v).Convert(rv.Type()))
130 default:
131 return &document.UnmarshalTypeError{Value: "bool", Type: rv.Type()}
132 }
133 return nil
134}
135
136func (d *decoder) decodeFloat(v float64, rv reflect.Value) error {
137 switch rv.Kind() {

Callers 1

decodeMethod · 0.95

Calls 1

SetMethod · 0.45

Tested by

no test coverage detected