Skip to content

Commit

Permalink
Add documentation comment for hashNamesFromList
Browse files Browse the repository at this point in the history
  • Loading branch information
florentc committed Mar 19, 2024
1 parent 312d084 commit 9245dc6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Cooked/Pretty/Options.hs
Original file line number Diff line number Diff line change
Expand Up @@ -106,5 +106,7 @@ defaultHashNames =
(permanentCurrencySymbol, "Permanent")
]

-- | Smart constructor for maps to be used in the "pcOptHashNames"
-- pretty-printing option.
hashNamesFromList :: (Hashable a) => [(a, String)] -> Map Pl.BuiltinByteString String
hashNamesFromList = Map.fromList . map (first toHash)

0 comments on commit 9245dc6

Please sign in to comment.