Hedi-0.1: Line oriented editor

Parser

Synopsis

Documentation

type ParseE = GenParser Char ()Source

shortcut for a parser of chars with no state

numero :: ParseE IntegerSource

parse an integer number

parseOffset :: ParseE OffsetSource

parse an Offset

parseRange :: ParseE RangeSource

parse a Range

defaultOR :: Command -> OffsetOrRangeSource

defaults Offset or Range for the commands

acceptOffsetOnly :: Command -> OffsetOrRange -> ParseE ()Source

forces a failure for a command if a Range was parsed

rconst :: Command -> ParseE (OffsetOrRange -> ParseE Command)Source

helper for skipping a filter

parseCommand :: ParseE (OffsetOrRange -> ParseE Command)Source

parse a function from OffsetOrRange to a parse Command

parser :: ParseE CompleteCommandSource

parse a CompleteCommand made of an OffsetOrRange and a Command

parse :: String -> Either String CompleteCommandSource

the parser from a String to either a String representing an error or a CompleteCommand