packages feed

hsemail 2.2.0 → 2.2.1

raw patch · 3 files changed

+6/−4 lines, 3 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

hsemail.cabal view
@@ -1,5 +1,5 @@ name:               hsemail-version:            2.2.0+version:            2.2.1 synopsis:           Parsec parsers for the Internet Message format (e-mail) description:        Parsec parsers for the Internet Message format defined in RFC2822. license:            BSD3@@ -10,7 +10,7 @@                     Marty Pauley maintainer:         Peter Simons <simons@cryp.to> stability:          stable-tested-with:        GHC == 7.10.3, GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.4, GHC == 8.6.5+tested-with:        GHC == 7.10.3 || == 8.0.2 || == 8.2.2 || == 8.4.4 || == 8.6.5 || == 8.8.4 || == 8.10.2 category:           Parsing homepage:           https://github.com/peti/hsemail#readme bug-reports:        https://github.com/peti/hsemail/issues
src/Text/Parsec/Rfc2822.hs view
@@ -309,7 +309,7 @@  day_of_month :: Stream s m Char => ParsecT s u m Int day_of_month = do r <- fmap read (manyNtoM 1 2 digit)-                  guard (r >= 1 && r < 31)+                  guard (r >= 1 && r <= 31)                   return r  -- | Match a 1 or 2-digit number (day of month), recognizing both standard and
test/spec.hs view
@@ -35,12 +35,14 @@    describe "Rfc2822.day" $ do     it "parses a hand-picked day-of-months correctly" $ do+      parseTest day "1" `shouldReturn` 1       parseTest day "09" `shouldReturn` 9       parseTest day "15" `shouldReturn` 15+      parseTest day "31" `shouldReturn` 31      it "does perform range checking" $ do       parseFailure day "00"-      parseFailure day "99"+      parseFailure day "32"      it "fails properly on incomplete input" $ do       parseFailure day "Mon"