func Is(err error) func(error) bool {
	return errors.Is(err)
}
Is returns a function that returns whether the
an error is equal to the given error.
It is intended to be used as a "shouldPreserveCause" argument
to Note. For example:

return errgo.Note(err, errgo.Is(http.ErrNoCookie), "")

would return an error with an http.ErrNoCookie cause
only if that was err's cause.
package errors
import (
	"gopkg.in/errgo.v2/errors"
)
type (
	Causer  = errors.Causer
	Wrapper = errors.Wrapper
	Locator = errors.Locator
)
type Locationer = errors.Locationer
func New(s string) error {
	err := errors.New(s)
	errors.SetLocation(err, 1)
	return err
}
func Note(err error, shouldPreserveCause func(error) bool, msg string) error {
	err = errors.Note(err, shouldPreserveCause, msg)
	errors.SetLocation(err, 1)
	return err
}
func Because(err, cause error, msg string) error {
	err = errors.Because(err, cause, msg)
	errors.SetLocation(err, 1)
	return err
}
func Wrap(err error) error {
	err = errors.Wrap(err)
	errors.SetLocation(err, 1)
	return err
}
func Cause(err error) error {
	return errors.Cause(err)
}
func SetLocation(err error, callDepth int) {
	errors.SetLocation(err, callDepth+1)
}
func Details(err error) string {
	return errors.Details(err)
}