ugorji / go

idiomatic codec and rpc lib for msgpack, cbor, json, etc. msgpack.org[Go]
MIT License
1.86k stars 295 forks source link

Added support for go 1.13+ error wrapping. #385

Closed dop251 closed 1 year ago

dop251 commented 1 year ago

Go 1.13 introduced an error wrapping mechanism that is similar, but incompatible with pkg/errors. This PR adds the (*codecError).Unwrap() method so that methods like errors.Is() work correctly.