HORIZON HASKELLDocslts/ghc-9.10.xc74966e2026-09-27Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27

Modulemegaparsec-9.7.0Haskell2010

Text.Megaparsec.State

Definition of Megaparsec's State.

  • 2 types
  • 2 values
  • Packagemegaparsec-9.7.0
  • Exports4
  • LanguageHaskell2010
  • LicenceBSD-2-Clause
  • SourceState.hs
datadata State s e
#

This is the Megaparsec's state parametrized over stream type s and custom error component type e.

Constructors

Instances6Eq, Data, Show, Generic, NFData, Rep
valueinitialState
  1. :: FilePath

    Name of the file the input is coming from

  2. -> s

    Input

  3. -> State s e
#

Given the name of the source file and the input construct the initial state for a parser.

datadata PosState s
#

A special kind of state that is used to calculate line/column positions on demand.

Constructors

Instances6Eq, Data, Show, Generic, NFData, Rep
valueinitialPosState
  1. :: FilePath

    Name of the file the input is coming from

  2. -> s

    Input

  3. -> PosState s
#

Given the name of source file and the input construct the initial positional state.