Documentation
¶
Index ¶
- func Cause(err error) error
- func Errorf(format string, args ...any) error
- func HasCause(source, target error) bool
- func HasType(source, target error) bool
- func Is(source, target error) bool
- func Join(errs ...error) error
- func New(msg string) error
- func WithMessage(err error, format string) error
- func WithMessagef(err error, format string, args ...any) error
- func WithStack(err error) error
- func Wrap(err error, message string) error
- func Wrapf(err error, format string, args ...any) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Errorf ¶
Errorf formats according to a format specifier and returns the string as a value that satisfies error. Errorf also records the stack trace at the point it was called.
func HasCause ¶
HasCause recursively checks errors wrapped using Wrapf until it detects the target error
func HasType ¶
HasType recursively checks errors wrapped using Wrapf until it detects the target error type
func New ¶
New returns an error with the supplied message. New also records the stack trace at the point it was called.
func WithMessage ¶ added in v0.6.0
WithMessage annotates err with the format specifier.
func WithMessagef ¶
WithMessagef annotates err with the format specifier.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.