Skip to content

Commit

Permalink
Support megaparsec 8
Browse files Browse the repository at this point in the history
  • Loading branch information
hpdeifel committed Jan 14, 2020
1 parent 15818f8 commit 6af30ff
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
6 changes: 3 additions & 3 deletions hledger-iadd.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ library
, transformers >= 0.3
, time >= 1.5
, vector
, megaparsec >= 7.0 && <7.1
, megaparsec >= 7.0 && <8.1
, containers
, optparse-applicative
, directory
Expand Down Expand Up @@ -102,7 +102,7 @@ executable hledger-iadd
, xdg-basedir
, unordered-containers
, free >= 4.12.4
, megaparsec >= 7.0 && <7.1
, megaparsec >= 7.0 && <8.1
ghc-options: -threaded -Wall -fdefer-typed-holes -fno-warn-name-shadowing

test-suite spec
Expand All @@ -124,7 +124,7 @@ test-suite spec
, hspec
, QuickCheck
, free >= 4.12.4
, megaparsec >= 7.0 && <7.1
, megaparsec >= 7.0 && <8.1
, text-zipper >= 0.10
build-tool-depends: hspec-discover:hspec-discover ==2.*
ghc-options: -threaded -Wall -fdefer-typed-holes -fno-warn-name-shadowing
4 changes: 4 additions & 0 deletions src/ConfigParser.hs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE GADTs, DeriveFunctor, ScopedTypeVariables #-}
{-# LANGUAGE CPP #-}

-- | Applicative config parser.
--
Expand Down Expand Up @@ -283,4 +284,7 @@ parseWithStart p pos s = snd (runParser' p state)
, pstateTabWidth = mkPos 1
, pstateLinePrefix = ""
}
#if MIN_VERSION_megaparsec(8,0,0)
, stateParseErrors = []
#endif
}

0 comments on commit 6af30ff

Please sign in to comment.