From a03fd1d89fcdca94c69288cd653840eaca8ccdee Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Sun, 27 May 2012 18:20:18 +0000 Subject: [PATCH] fix haddock complaints --- hledger-lib/Hledger/Data/Amount.hs | 6 +++--- hledger-lib/Hledger/Reports.hs | 6 ------ 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/hledger-lib/Hledger/Data/Amount.hs b/hledger-lib/Hledger/Data/Amount.hs index bdd46d50d..db18b3d18 100644 --- a/hledger-lib/Hledger/Data/Amount.hs +++ b/hledger-lib/Hledger/Data/Amount.hs @@ -148,13 +148,13 @@ isNegativeAmount Amount{quantity=q} = q < 0 -- | Does this amount appear to be zero when displayed with its given precision ? isZeroAmount :: Amount -> Bool -isZeroAmount a -- | a==missingamt = False +isZeroAmount a -- a==missingamt = False | otherwise = (null . filter (`elem` "123456789") . showAmountWithoutPriceOrCommodity) a -- | Is this amount "really" zero, regardless of the display precision ? -- Since we are using floating point, for now just test to some high precision. isReallyZeroAmount :: Amount -> Bool -isReallyZeroAmount a -- | a==missingamt = False +isReallyZeroAmount a -- a==missingamt = False | otherwise = (null . filter (`elem` "123456789") . printf ("%."++show zeroprecision++"f") . quantity) a where zeroprecision = 8 @@ -392,7 +392,7 @@ showMixedAmountWithPrecision p m = showMixedAmountDebug :: MixedAmount -> String showMixedAmountDebug m | m == missingmixedamt = "(missing)" | otherwise = printf "Mixed [%s]" as - where as = intercalate "\n " $ map showAmountDebug $ amounts m -- $ normaliseMixedAmountPreservingFirstPrice m + where as = intercalate "\n " $ map showAmountDebug $ amounts m -- normaliseMixedAmountPreservingFirstPrice m -- | Get the string representation of a mixed amount, but without -- any \@ prices. diff --git a/hledger-lib/Hledger/Reports.hs b/hledger-lib/Hledger/Reports.hs index 03f4d3711..9b2e16dcd 100644 --- a/hledger-lib/Hledger/Reports.hs +++ b/hledger-lib/Hledger/Reports.hs @@ -223,12 +223,6 @@ type EntriesReport = [EntriesReportItem] type EntriesReportItem = Transaction -- | Select transactions for an entries report. --- "The print command selects transactions which --- @ --- match any of the description patterns --- and have any postings matching any of the positive account patterns --- and have no postings matching any of the negative account patterns" --- @ entriesReport :: ReportOpts -> Query -> Journal -> EntriesReport entriesReport opts q j = sortBy (comparing date) $ filter (q `matchesTransaction`) ts