forked from OSS/graphql
Update to Stack 15.x
This commit is contained in:
parent
c0e5e30e76
commit
613e929d91
@ -15,7 +15,6 @@ module Language.GraphQL.AST.Encoder
|
||||
|
||||
import Data.Char (ord)
|
||||
import Data.Foldable (fold)
|
||||
import Data.Monoid ((<>))
|
||||
import qualified Data.List.NonEmpty as NonEmpty
|
||||
import Data.Text (Text)
|
||||
import qualified Data.Text as Text
|
||||
|
@ -20,7 +20,9 @@ import Control.Monad.Trans.State ( StateT
|
||||
, modify
|
||||
, runStateT
|
||||
)
|
||||
import Text.Megaparsec ( ParseErrorBundle(..)
|
||||
import Text.Megaparsec
|
||||
( ParseErrorBundle(..)
|
||||
, PosState(..)
|
||||
, SourcePos(..)
|
||||
, errorOffset
|
||||
, parseErrorTextPretty
|
||||
@ -39,7 +41,8 @@ parseError ParseErrorBundle{..} =
|
||||
, ("column", Aeson.toJSON $ unPos sourceColumn)
|
||||
]
|
||||
go (result, state) x =
|
||||
let (sourcePosition, _, newState) = reachOffset (errorOffset x) state
|
||||
let (_, newState) = reachOffset (errorOffset x) state
|
||||
sourcePosition = pstateSourcePos newState
|
||||
in (errorObject x sourcePosition : result, newState)
|
||||
|
||||
-- | A wrapper to pass error messages around.
|
||||
|
@ -1,4 +1,4 @@
|
||||
resolver: lts-14.25
|
||||
resolver: lts-15.0
|
||||
|
||||
packages:
|
||||
- .
|
||||
|
@ -16,7 +16,6 @@ module Test.StarWars.Data
|
||||
, typeName
|
||||
) where
|
||||
|
||||
import Data.Monoid (mempty)
|
||||
import Data.Functor.Identity (Identity)
|
||||
import Control.Applicative (Alternative(..), liftA2)
|
||||
import Control.Monad.Trans.Except (throwE)
|
||||
|
Loading…
Reference in New Issue
Block a user