to/ptr.go (4 lines of code) (raw):

package to // Ptr returns a pointer to the provided value. func Ptr[T any](v T) *T { return &v }