HORIZON HASKELLDocslts/ghc-9.10.xc74966e2026-09-27Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27

Moduleoptics-extra-0.4.2.1Haskell2010

Data.HashSet.Optics

This module defines optics for constructing and manipulating finite HashSets.

  • 2 values
valuesetOf
  1. :: (Is k A_Fold, Eq a, Hashable a)
  2. => Optic' k is s a
  3. -> s
  4. -> HashSet a
#

Construct a HashSet from a fold.

Example1 expression
setOf folded ["hello","world"]fromList ["hello","world"]
Example1 expression
setOf (folded % _2) [("hello",1),("world",2),("!!!",3)]fromList [1,2,3]