on master help sign in
Add some haddock comments.
commitf895f1bdd0b0afa374801f69ef88db8685aacb68 authorNick <nick@typeable.io> dateMon 28 Nov 2022, 12:03 (4 years ago) parenta40bf77
1 file changed+6
src/Data/Money/Internal.hs+6
src/Data/Money/Internal.hs+6
@@ -15,11 +15,17 @@ import Data.Proxy
1515import GHC.Generics
1616import GHC.TypeLits
1717
18+-- | Money type. This is actually 'Centi' from 'Data.Fixed' in disguise.
19+-- The type parameter is phantom, you probably want to use 'Currency' there.
20+-- See also 'Data.Money.Currencies' for currency types.
1821newtype Money curr = Money { getAmount :: Centi }
1922 deriving (Eq, Ord, Generic)
2023
24+-- | Empty type, used only to carry its type parameter with a currency code around. E.g. 'Currency "USD"', 'Currency "GBP"', et cetera.
25+-- See Data.Money.Currencies for pre-defined currency types.
2126data Currency (name :: Symbol)
2227
28+-- | Statically known currency type class.
2329class KnownCurrency c where
2430 currencyCode :: String
2531