glualint-1.24.6: Attempts to fix your syntax erroring Lua files.
Safe HaskellSafe-Inferred
LanguageHaskell2010

GLua.PSLexer

Synopsis

Documentation

rgStart2sp :: Region -> SourcePos Source #

Region start to SourcePos

rgEnd2sp :: Region -> SourcePos Source #

Region end to SourcePos

sp2Rg :: SourcePos -> Region Source #

SourcePos to region

lcp2sp :: LineColPos -> SourcePos Source #

LineColPos to SourcePos

sp2lcp :: SourcePos -> LineColPos Source #

SourcePos to LineColPos

pPos :: Parser LineColPos Source #

Get the source position

pUntilEnd :: Parser String Source #

Parse the string until the end. Used in parseLineComment among others.

parseWhitespace :: Parser String Source #

Whitespace parser that requires at least one whitespace character

parseOptionalWhitespace :: Parser String Source #

Whitespace parser that requires 0 or more whitespace characters

escapedStringChar :: Char -> Parser String Source #

An escaped character of a single line string Takes the delimiter of the string as parameter

startNestedString :: Parser String Source #

The start of a nested string Returns the amount of =-signs at the start of the nested string

nestedString :: String -> Parser String Source #

Parses a multiline string returns the amount of =-signs in the string delimiter and the contents

parseLuaComment :: Parser Token Source #

Parse Lua style comments

parseCComment :: Parser Token Source #

Parse C-Style comments

parseComment :: Parser Token Source #

Parse any kind of comment.

nestedStringToMLString :: String -> String -> Token Source #

Convert the result of the nestedString parser to a MultiLine string

parseLineString :: Char -> Parser String Source #

Parse single line strings e.g. "sdf", werf.

parseString :: Parser Token Source #

Single and multiline strings.

parseNumber :: Parser Token Source #

Parse any kind of number. Except for numbers that start with a .. That's handled by parseDots to solve ambiguity.

parseKeyword :: Token -> String -> Parser Token Source #

Parse either a keyword or an identifier that starts with that keyword

parseIdentifier :: Parser String Source #

Parse just an identifier.

parseLabel :: Parser String Source #

Parse a label.

parseDots :: Parser Token Source #

Parse anything to do with dots. Indexaction (.), concatenation (..), varargs (...) or numbers that start with a dot

parseToken :: Parser Token Source #

Parse any kind of token.

annotated :: (Region -> a -> b) -> Parser a -> Parser b Source #

A thing of which the region is to be parsed

parseMToken :: Parser MToken Source #

parse located MToken

parseTokens :: Parser [MToken] Source #

Parse a list of tokens and turn them into MTokens.

parseHashBang :: Parser String Source #

Parse the potential #!comment on the first line Lua ignores the first line if it starts with #

execParseTokens :: String -> Either ParseError [MToken] Source #

Parse a string into MTokens.