mangrove-0.1.0.0: A parser for web documents according to the HTML5 specification.
Copyright(c) 2020 Sam May
LicenseMPL-2.0
Maintainerag.eitilt@gmail.com
Stabilityexperimental
Portabilityportable
Safe HaskellSafe-Inferred
LanguageHaskell98

Web.Mangrove.Parse.Common.Error

Description

 
Synopsis

Documentation

data ParseError Source #

HTML: parse errors (constructor names directly reflect the identifiers in the spec)

Indicators that something syntactically unexpected was found in an HTML file. Given the focus on recovery in the parse algorithm, these are more properly warnings than errors, but the name follows that in the specification.

This datatype consists of the union of the errors raised by any of the various stages of the algorithm; no distinction is made between an "encoding error" and a "tree-building error".

Several constructors wrap a payload which would otherwise be unrecoverable from the DOM, to enable richer error reporting.

Constructors

AbruptTemplateFragment 
AbruptClosingOfEmptyComment 
AbruptDoctypePublicIdentifier 
AbruptDoctypeSystemIdentifier 
AbsenceOfDigitsInNumericCharacterReference 
BREndTag 
CDataInHtmlContent 
CharacterReferenceOutsideUnicodeRange Natural 
ControlCharacterInInputStream 
ControlCharacterReference 
DuplicateAttribute BasicAttribute 
DuplicateSingletonElement ElementParams 
EndTagWithAttributes 
EndTagWithTrailingSolidus 
EOFBeforeTagName 
EOFInCData 
EOFInComment 
EOFInDoctype 
EOFInScriptHtmlCommentLikeText 
EOFInTag 
EOFInTemplate 
EOFInText 
FramesetInBody ElementParams 
IncompletelyClosedFormattingElement 
IncorrectlyClosedComment 
IncorrectlyOpenedComment 
InvalidByteSequence ShortByteString 
InvalidCharacterSequenceAfterDoctypeName 
InvalidFirstCharacterOfTagName 
LegacyDoctype 
MalformedTableStructure ElementParams 
MissingAttributeValue 
MissingDoctype 
MissingDoctypeName 
MissingDoctypePublicIdentifier 
MissingDoctypeSystemIdentifier 
MissingEndTagName 
MissingQuoteBeforeDoctypePublicIdentifier 
MissingQuoteBeforeDoctypeSystemIdentifier 
MissingSemicolonAfterCharacterReference 
MissingWhitespaceAfterDoctypePublicKeyword 
MissingWhitespaceAfterDoctypeSystemKeyword 
MissingWhitespaceBeforeDoctypeName 
MissingWhitespaceBetweenAttributes 
MissingWhitespaceBetweenDoctypePublicAndSystemIdentifiers 
NestedComment 
NestedElementForAdoptionAgency 
NestedNonRecursiveElement 
NestedSingletonElement 
NoncharacterCharacterReference Char 
NoncharacterInInputStream 
NonVoidHtmlElementStartTagWithTrailingSolidus 
NullCharacterReference 
ObsoleteTagName Text 
OverlappingFormattingElements 
OverlappingHeaderElements 
OverlappingInputElements 
SurrogateCharacterReference Char 
SurrogateInInputStream 
UnexpectedCharacterAfterDoctypeSystemIdentifier Char 
UnexpectedCharacterInAttributeName 
UnexpectedCharacterInUnquotedAttributeValue 
UnexpectedContentAfterBody 
UnexpectedDescendantElement ElementParams 
UnexpectedDoctype DocumentTypeParams 
UnexpectedElementInTableStructure 
UnexpectedElementWithImpliedEndTag 
UnexpectedEqualsSignBeforeAttributeName 
UnexpectedEndColInColumnGroup 
UnexpectedEndOfBody 
UnexpectedEndTag ElementParams 
UnexpectedFormattingElementOutOfScope 
UnexpectedHtmlElementInForeignContent 
UnexpectedMetadataOutsideOfHead 
UnexpectedNodeAfterFrameset 
UnexpectedNodeInFrameset 
UnexpectedNodeInHeadNoscript 
UnexpectedNodeInTableStructure 
UnexpectedNullCharacter 
UnexpectedQuestionMarkInsteadOfTagName 
UnexpectedSolidusInTag 
UnexpectedTableCellOutsideOfRow 
UnexpectedTextInTableStructure 
UnknownNamedCharacterReference 
UnmatchedEndTag ElementParams 
UnmatchedEndPTag 
XmlnsAttribtuteWithMismatchedValue