3 // This is a type that wraps error types so that they can be messaged
4 // across RPC channels. Since "error" is an interface, we can't always
5 // gob-encode the underlying structure. This is a valid error interface
6 // implementer that we will push across.
7 type BasicError struct {
11 // NewBasicError is used to create a BasicError.
13 // err is allowed to be nil.
14 func NewBasicError(err error) *BasicError {
19 return &BasicError{err.Error()}
22 func (e *BasicError) Error() string {