on master help sign in
Document DBNum and DBFractional
commit188bdd07538995cba9dda08bf60f873d1a988c19 authorOllie Charles <ollie@ocharles.org.uk> dateWed 24 Mar 2021, 11:55 (6 years ago) parenteceab83
1 file changed+3−1
src/Rel8/Type/Num.hs+3−1
src/Rel8/Type/Num.hs+3−1
@@ -19,6 +19,8 @@ import Rel8.Type ( DBType )
1919import Data.Scientific ( Scientific )
2020
2121
22+-- | The class of database types that support the @+@, @*@, @-@ operators, and
23+-- the @abs@, @negate@, @sign@ functions.
2224type DBNum :: Type -> Constraint
2325class DBType a => DBNum a
2426instance DBNum Int16
@@ -36,7 +38,7 @@ instance DBIntegral Int32
3638instance DBIntegral Int64
3739
3840
39−type DBFractional :: Type -> Constraint
41+-- | The class of database types that support the @/@ operator.
4042class DBNum a => DBFractional a
4143instance DBFractional Float
4244instance DBFractional Double