func parseFloat64Bytes(bts []byte) (float64, []byte, error) {
	if msgp.IsNil(bts) {
		bts, err := msgp.ReadNilBytes(bts)
		return 0, bts, err
	}
	// read the generic representation type without decoding
	t := msgp.NextType(bts)

	var err error
	switch t {
	case msgp.IntType:
		var i int64
		i, bts, err = msgp.ReadInt64Bytes(bts)
		if err != nil {
			return 0, bts, err
		}

		return float64(i), bts, nil
	case msgp.UintType:
		var i uint64
		i, bts, err = msgp.ReadUint64Bytes(bts)
		if err != nil {
			return 0, bts, err
		}

		return float64(i), bts, nil
	case msgp.Float64Type:
		var f float64
		f, bts, err = msgp.ReadFloat64Bytes(bts)
		if err != nil {
			return 0, bts, err
		}

		return f, bts, nil
	default:
		return 0, bts, msgp.TypeError{Encoded: t, Method: msgp.Float64Type}
	}
}
// parseFloat64Bytes parses a float64 even if the sent value is an int64 or an uint64;
// this is required because the encoding library could remove bytes from the encoded
// payload to reduce the size, if they're not needed.
parseFloat64Bytes parses a float64 even if the sent value is an int64 or an uint64;
this is required because the encoding library could remove bytes from the encoded
payload to reduce the size, if they're not needed.
// parseFloat64Bytes parses a float64 even if the sent value is an int64 or an uint64 ; // this is required because the encoding library could remove bytes from the encoded // payload to reduce the size if they ' re not needed .
func parseFloat64Bytes(bts []byte) (float64, []byte, error) {
	if msgp.IsNil(bts) {
		bts, err := msgp.ReadNilBytes(bts)
		return 0, bts, err
	}
	t := msgp.NextType(bts)
	var err error
	switch t {
	case msgp.IntType:
		var i int64
		i, bts, err = msgp.ReadInt64Bytes(bts)
		if err != nil {
			return 0, bts, err
		}
		return float64(i), bts, nil
	case msgp.UintType:
		var i uint64
		i, bts, err = msgp.ReadUint64Bytes(bts)
		if err != nil {
			return 0, bts, err
		}
		return float64(i), bts, nil
	case msgp.Float64Type:
		var f float64
		f, bts, err = msgp.ReadFloat64Bytes(bts)
		if err != nil {
			return 0, bts, err
		}
		return f, bts, nil
	default:
		return 0, bts, msgp.TypeError{Encoded: t, Method: msgp.Float64Type}
	}
}
func parseFloat64Bytes ( bts [ ] byte ) ( float64 , [ ] byte , error ) { if msgp . IsNil ( bts ) { bts , err := msgp . ReadNilBytes ( bts ) return 0 , bts , err } t := msgp . NextType ( bts ) var err error switch t { case msgp . IntType : var i int64 i , bts , err = msgp . ReadInt64Bytes ( bts ) if err != nil { return 0 , bts , err } return float64 ( i ) , bts , nil case msgp . UintType : var i uint64 i , bts , err = msgp . ReadUint64Bytes ( bts ) if err != nil { return 0 , bts , err } return float64 ( i ) , bts , nil case msgp . Float64Type : var f float64 f , bts , err = msgp . ReadFloat64Bytes ( bts ) if err != nil { return 0 , bts , err } return f , bts , nil default : return 0 , bts , msgp . TypeError { Encoded : t , Method : msgp . Float64Type } } }
parseFloat64Bytes parses a float64 even if the sent value is an int64 or an uint64;
this is required because the encoding library could remove bytes from the encoded
payload to reduce the size, if they're not needed.
parseFloat64Bytes parses a float64 even if the sent value is an int64 or an uint64 ; this is required because the encoding library could remove bytes from the encoded payload to reduce the size if they ' re not needed .
// read the generic representation type without decoding