package
Version:
v0.11.1
Opens a new window with list of versions in this module.
Published: Oct 19, 2022
License: MIT
Opens a new window with license information.
Imports: 3
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Package singleton provides a singleton set.
package main
import (
"fmt"
"github.com/phelmkamp/valor/tuple/singleton"
)
func main() {
fmt.Println(singleton.SetOf(42))
}
Output:
{42}
SetUnzip separates the values of t into two Sets.
SetZip combines the values of s and s2 into a two.Tuple.
Set contains at most one element.
It works like a map. Use the key unit.Unit to access the element:
v, ok := s[unit.Unit]
SetOf creates a Set of v.
String returns the Set formatted as a string.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.