Documentation ¶
Overview ¶
Package errorx contains utilities for handling errors.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GuardedError ¶
type GuardedError struct {
// contains filtered or unexported fields
}
GuardedError is a concurrency-safe error wrapper. It is sticky in that the first error won't be overwritten.
func (*GuardedError) TrySetError ¶
func (g *GuardedError) TrySetError(err error) bool
TrySetError sets the error, if not already set. Returns true iff the error was set.
Click to show internal directories.
Click to hide internal directories.