Compiler.Parse.String
This module provides parsers for Gren string and character literals.
char :
Parser Context Error Char
Use this to parse character literals.
String.Parser.run char Compiler.Parse.Context.empty source
string :
Parser Context Error String
Use this to parse string literals.
String.Parser.run string Compiler.Parse.Context.empty source
type Error
= ExpectedQuote
| ExpectedChar
| ExpectedEscapeChar String
| ExpectedUnicodeOpening
| ExpectedValidUnicode
| ExpectedUnicodeClosing
| ExpectedNewline
| MisalignedMultiQuotes
The kind of errors that can happen while parsing characters and strings.
errorToString :
Error -> String
Returns a human-readable description of an Error.