Support extracting underlying error list (#19)

This change adds an `Errors(err) []error` function which returns the
underlying list of errors. Additionally, it amends the contract for
returned errors that they MAY implement a specific interface.

This is needed for Zap integration as per discussion in #6.

Resolves #10.

2 files changed
tree: 928bc99b5d6fb6a7ef08254b117413c9270178b1
  1. scripts/
  2. .codecov.yml
  3. .gitignore
  4. .travis.yml
  5. benchmarks_test.go
  6. CHANGELOG.md
  7. error.go
  8. error_test.go
  9. glide.lock
  10. glide.yaml
  11. LICENSE.txt
  12. Makefile
  13. README.md
README.md

multierr GoDoc Build Status Coverage Status

multierr allows combining one or more Go errors together.

Installation

go get -u go.uber.org/multierr

Status

Stable: No breaking changes will be made before 2.0.


Released under the MIT License.