package grand

import "xdx.jelly/xgcl/gerrors"

//go:generate stringer -type=ErrorCode -linecomment -output=errors_string.go errors.go
type ErrorCode gerrors.ErrorCode

func (e ErrorCode) Error() string {
	return gerrors.Format(uint32(e), e.String())
}

// error codes
const (
	ErrGenerateRandomFailed ErrorCode = gerrors.XDX_JELLY_GCL_GRAND + iota //随机数生成失败
)
