func MarshalConsensusState(cdc codec.BinaryCodec, cs exported.ConsensusState) ([]byte, error) {
	return cdc.MarshalInterface(cs)
}
MarshalConsensusState protobuf serializes a ConsensusState interface
package types
import (
	"fmt"
	"github.com/cosmos/cosmos-sdk/codec"
	"github.com/bianjieai/tibc-go/modules/tibc/core/exported"
)
func MustUnmarshalClientState(cdc codec.BinaryCodec, bz []byte) exported.ClientState {
	clientState, err := UnmarshalClientState(cdc, bz)
	if err != nil {
		panic(fmt.Errorf("failed to decode client state: %w", err))
	}
	return clientState
}
func MustMarshalClientState(cdc codec.BinaryCodec, clientState exported.ClientState) []byte {
	bz, err := MarshalClientState(cdc, clientState)
	if err != nil {
		panic(fmt.Errorf("failed to encode client state: %w", err))
	}
	return bz
}
func MarshalClientState(cdc codec.BinaryCodec, clientStateI exported.ClientState) ([]byte, error) {
	return cdc.MarshalInterface(clientStateI)
}
func UnmarshalClientState(cdc codec.BinaryCodec, bz []byte) (exported.ClientState, error) {
	var clientState exported.ClientState
	if err := cdc.UnmarshalInterface(bz, &clientState); err != nil {
		return nil, err
	}
	return clientState, nil
}
func MustUnmarshalConsensusState(cdc codec.BinaryCodec, bz []byte) exported.ConsensusState {
	consensusState, err := UnmarshalConsensusState(cdc, bz)
	if err != nil {
		panic(fmt.Errorf("failed to decode consensus state: %w", err))
	}
	return consensusState
}
func MustMarshalConsensusState(cdc codec.BinaryCodec, consensusState exported.ConsensusState) []byte {
	bz, err := MarshalConsensusState(cdc, consensusState)
	if err != nil {
		panic(fmt.Errorf("failed to encode consensus state: %w", err))
	}
	return bz
}