import "github.com/cockroachdb/cockroach/pkg/util/causer"
Visit walks along the chain of errors until it encounters the first one that does not implement Causer. The visitor is invoked with each error visited until there are no more errors to visit or the visitor returns true (which is then the return value of Visit as well). Returns false when the visitor never returns true or if the initial error is nil. Calling this method on a cyclic error chain results in an infinite loop.
A Causer is an error that wraps a causing error (which in turn could be another Causer). A Causer is usually constructed via errors.Wrap or Wrapf.
Package causer is imported by 1 packages. Updated 2019-07-16. Refresh now. Tools for package owners.