HORIZON HASKELLDocslts/ghc-9.10.x248f8f02026-10-05Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05

Moduletoml-parser-2.0.0.0Haskell2010

Toml.Syntax.Position

This module provides the Position type for tracking locations in files while doing lexing and parsing for providing more useful error messages.

This module assumes 8 column wide tab stops.

  • 2 types
  • 2 values
datadata Located a
#

A value annotated with its text file position

Constructors

Instances5Functor, Foldable, Traversable, Read, Show
  • Functor LocatedDefined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

  • Foldable LocatedDefined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

  • Traversable LocatedDefined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

  • Read a => Read (Located a)Defined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

  • Show a => Show (Located a)Defined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

datadata Position
#

A position in a text file

Constructors

Instances4Eq, Ord, Read, Show
  • Eq PositionDefined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

  • Ord PositionDefined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

  • Read PositionDefined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

  • Show PositionDefined in toml-parser-2.0.0.0 · Toml.Syntax.Position

    Default instance

valuemove :: Char -> Position -> Position
#

Adjust a file position given a single character handling newlines and tabs. All other characters are considered to fill exactly one column.