Documentation ¶
Overview ¶
Package pointer provides helper functions related to Go pointers.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Eq ¶ added in v1.2.12
Eq returns whether a and b are equal in underlying value.
May only be used on pointers to primitive types, where the comparison is guaranteed to be sensible. For complex types (i.e. structs) consider implementing an Equal method.
Types ¶
type Primitive ¶ added in v1.2.12
type Primitive interface { constraints.Ordered | bool }
Primitive represents basic types that are safe to do basic comparisons by pointer dereference (checking nullity first).
Click to show internal directories.
Click to hide internal directories.