package
0.7.0
Repository: https://github.com/google/go-cmp.git
Documentation: pkg.go.dev

# Functions

AcyclicTransformer returns a [cmp.Transformer] with a filter applied that ensures that the transformer cannot be recursively applied upon its own output.
EquateApprox returns a [cmp.Comparer] option that determines float32 or float64 values to be equal if they are within a relative fraction or absolute margin.
EquateApproxTime returns a [cmp.Comparer] option that determines two non-zero [time.Time] values to be equal if they are within some margin of one another.
EquateComparable returns a [cmp.Option] that determines equality of comparable types by directly comparing them using the == operator in Go.
EquateEmpty returns a [cmp.Comparer] option that determines all maps and slices with a length of zero to be equal, regardless of whether they are nil.
EquateErrors returns a [cmp.Comparer] option that determines errors to be equal if [errors.Is] reports them to match.
EquateNaNs returns a [cmp.Comparer] option that determines float32 and float64 NaN values to be equal.
IgnoreFields returns an [cmp.Option] that ignores fields of the given names on a single struct type.
IgnoreInterfaces returns an [cmp.Option] that ignores all values or references of values assignable to certain interface types.
IgnoreMapEntries returns an [cmp.Option] that ignores entries of map[K]V.
IgnoreSliceElements returns an [cmp.Option] that ignores elements of []V.
IgnoreTypes returns an [cmp.Option] that ignores all values assignable to certain types, which are specified by passing in a value of each type.
IgnoreUnexported returns an [cmp.Option] that only ignores the immediate unexported fields of a struct, including anonymous fields of unexported types.
SortMaps returns a [cmp.Transformer] option that flattens map[K]V types to be a sorted []struct{K, V}.
SortSlices returns a [cmp.Transformer] option that sorts all []V.

# Variables

AnyError is an error that matches any non-nil error.