MCPcopy Create free account
hub / github.com/google/go-cloud / wrap

Function wrap

docstore/driver/codec.go:734–739  ·  view source on GitHub ↗
(err error, code gcerr.ErrorCode)

Source from the content-addressed store, hash-verified

732}
733
734func wrap(err error, code gcerr.ErrorCode) error {
735 if _, ok := err.(*gcerr.Error); !ok && err != nil {
736 err = gcerr.New(code, err, 2, err.Error())
737 }
738 return err
739}
740
741var fieldCache = fields.NewCache(parseTag, nil, nil)
742

Callers 2

EncodeFunction · 0.85
DecodeFunction · 0.85

Calls 2

NewFunction · 0.92
ErrorMethod · 0.45

Tested by

no test coverage detected