Documentation ¶ Index ¶ type Option func Fmap[T any, R any](opt Option[T], f func(x T) R) Option[R] func None[T any]() Option[T] func Some[T any](x T) Option[T] func (opt Option[T]) IsSome() bool func (opt *Option[T]) Replace(x T) func (opt Option[T]) ToString() string func (opt Option[T]) Unwrap() T Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type Option ¶ type Option[T any] struct { // contains filtered or unexported fields } func Fmap ¶ func Fmap[T any, R any](opt Option[T], f func(x T) R) Option[R] func None ¶ func None[T any]() Option[T] func Some ¶ func Some[T any](x T) Option[T] func (Option[T]) IsSome ¶ func (opt Option[T]) IsSome() bool func (*Option[T]) Replace ¶ func (opt *Option[T]) Replace(x T) func (Option[T]) ToString ¶ func (opt Option[T]) ToString() string func (Option[T]) Unwrap ¶ func (opt Option[T]) Unwrap() T Source Files ¶ View all Source files option.go Click to show internal directories. Click to hide internal directories.