@@ -18,7 +18,7 @@ Portability : portable
1818lookups, and deletion. A 'HashSet' makes no guarantees as to the order of its
1919elements.
2020
21- If you are storing sets of @ Int@ s consider using the @ Data.IntSet@ from the
21+ If you are storing sets of "Data. Int" s consider using " Data.IntSet" from the
2222<https://hackage.haskell.org/package/containers containers> package.
2323
2424
4242Add a new entry to the set:
4343
4444>>> let moreDataStructures = HashSet.insert "Trie" dataStructures
45- >>> HashSet.member \ "Trie\ " moreDataStructures
45+ >>> HashSet.member "Trie" moreDataStructures
4646> True
4747
4848Remove the @\"Graph\"@ entry from the set of data structures.
@@ -60,11 +60,11 @@ fromList ["Map","HashSet","Graph","HashMap","Set","Sequence"]
6060
6161=== Using custom data with HashSet
6262
63- To create a @HashSet@ of your custom type, the type must have instances for 'Eq'
64- and ' Hashable' . The ' Hashable' typeclass is defined in the
63+ To create a @HashSet@ of your custom type, the type must have instances for "Data.Eq"
64+ and "Data. Hashable" . The @ Hashable@ typeclass is defined in the
6565<https://hackage.haskell.org/package/hashable hashable> package, see the
6666documentation for information on how to make your type an instance of
67- ' Hashable' .
67+ "Data. Hashable" .
6868
6969We'll start by setting up our custom data type:
7070
@@ -84,7 +84,7 @@ fromList [Person {name = "Simon", likesDogs = True},Person {name = "Lana", likes
8484== Performance
8585
8686The implementation is based on /hash array mapped tries/. A
87- 'HashSet' is often faster than other ' Ord' -based set types,
87+ 'HashSet' is often faster than other "Data. Ord" -based set types,
8888especially when value comparisons are expensive, as in the case of
8989strings.
9090
0 commit comments