package
Version:
v3.0.0-alpha2.105
Opens a new window with list of versions in this module.
Published: Jun 21, 2026
License: MIT
Opens a new window with license information.
Imports: 0
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
False is a Bool set to false.
True is a Bool set to true.
Bool is an optional bool value.
NewBool creates a new Bool with the given value.
type Var[T any] struct {
}
Var is a generic optional value that tracks whether it has been set.
func NewVar[T any](val T) Var[T]
NewVar creates a new Var with the given value, marked as set.
Get returns the value, or the zero value if unset.
IsSet reports whether a value has been assigned.
func (v *Var[T]) Set(val T)
Set assigns a value and marks the variable as set.
Unset resets the variable to the zero value and marks it as unset.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.