Documentation ¶ Overview ¶ Package eithererr provides utilities for working with functions that return either a value or an error. Index ¶ func ConstErr[A any](msg string) func(A) error Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func ConstErr ¶ func ConstErr[A any](msg string) func(A) error ConstErr returns a function that ignores its argument and always returns the same pre-allocated errors.New(msg) instance. This means callers using errors.Is for sentinel matching get stable identity across calls. Types ¶ This section is empty. Source Files ¶ View all Source files errors.go Click to show internal directories. Click to hide internal directories.