Versions in this module Expand all Collapse all v0 v0.1.0 Oct 27, 2026 Changes in this version + var ErrCrossPackageError = errors.New("error from different doterr package") + var ErrDiffUtils = errors.New("diffutils") + var ErrEmptyInput = errors.New("empty input") + var ErrInvalidArgumentType = errors.New("invalid argument type") + var ErrMisplacedError = errors.New("error in wrong position") + var ErrMissingSentinel = errors.New("missing required sentinel error") + var ErrNilContent = errors.New("nil content") + var ErrOddKeyValueCount = errors.New("odd number of key-value arguments") + var ErrTrailingKey = errors.New("trailing key without value") + func AppendErr(errs []error, err error) []error + func CombineErrs(errs []error) error + func ErrValue[T any](err error, key string) (T, bool) + func Errors(err error) []error + func FindErr[T error](err error) (out T, ok bool) + func GetContextDiffString(diff ContextDiff) (string, error) + func GetUnifiedDiffString(diff UnifiedDiff) (string, error) + func MsgErr(msg any) error + func NewErr(parts ...any) error + func SplitLines(s string) []string + func WithErr(parts ...any) error + func WriteContextDiff(writer io.Writer, diff ContextDiff) error + func WriteUnifiedDiff(writer io.Writer, diff UnifiedDiff) (err error) + type ChangeType int + const LinesAdded + const LinesDeleted + func (ct ChangeType) String() string + type ContextDiff UnifiedDiff + type DiffChange struct + NewRange LineRange + OldRange LineRange + Type ChangeType + type DiffContent struct + Changes []DiffChange + Label string + NewLines []string + OldLines []string + func DiffLines(old, new []string, label string) (content *DiffContent, err error) + type DiffSource interface + DiffContent func() (*DiffContent, error) + type ErrKV interface + Key func() string + Value func() any + func AnyKV(key string, value any) ErrKV + func AppendKV(kvs []ErrKV, parts ...any) []ErrKV + func BoolKV(key string, value bool) ErrKV + func ErrMeta(err error) []ErrKV + func ErrorKV(key string, value error) ErrKV + func Float64KV(key string, value float64) ErrKV + func Int64KV(key string, value int64) ErrKV + func IntKV(key string, value int) ErrKV + func StringKV(key, value string) ErrKV + type InlineHighlighter interface + HighlightInline func(oldLine, newLine string) (oldResult, newResult string) + type IsDotErrEntry = interface + HasKV func(key string, value any) bool + IsDotErrEntry func() + MatchKV func(key string, value any) bool + type LineRange struct + Count int + Start int + type Match struct + A int + B int + Size int + type OpCode struct + I1 int + I2 int + J1 int + J2 int + Tag byte + type SequenceMatcher struct + IsJunk func(string) bool + func NewMatcher(a, b []string) *SequenceMatcher + func NewMatcherWithJunk(a, b []string, autoJunk bool, isJunk func(string) bool) *SequenceMatcher + func (m *SequenceMatcher) GetGroupedOpCodes(n int) [][]OpCode + func (m *SequenceMatcher) GetMatchingBlocks() []Match + func (m *SequenceMatcher) GetOpCodes() []OpCode + func (m *SequenceMatcher) QuickRatio() float64 + func (m *SequenceMatcher) Ratio() float64 + func (m *SequenceMatcher) RealQuickRatio() float64 + func (m *SequenceMatcher) SetSeq1(a []string) + func (m *SequenceMatcher) SetSeq2(b []string) + func (m *SequenceMatcher) SetSeqs(a, b []string) + type UnifiedDiff struct + A []string + B []string + Context int + Eol string + FromDate string + FromFile string + ToDate string + ToFile string