fix some edge cases in parser

This commit is contained in:
Mark
2024-06-26 20:27:29 +02:00
parent b6c0391833
commit 1b79cfc08f
5 changed files with 132 additions and 112 deletions

View File

@@ -81,6 +81,7 @@ pub enum EColor {
AsTypeTypeAnnotation,
BadCharInTupleType,
BadCharInFunctionType,
BadCharAtStartOfStatement,
BadTypeFromParsed,
TypeAnnotationNoClosingBracket,
TryBadSyntax,

View File

@@ -70,8 +70,7 @@ pub fn default_theme<C>(
UnknownVariable => hard_err,
BackslashEscapeUnknown => hard_err,
BackslashEscapeEOF | StringEOF | TypeEOF => missing,
BadCharInTupleType => hard_err,
BadCharInFunctionType => hard_err,
BadCharInTupleType | BadCharInFunctionType | BadCharAtStartOfStatement => hard_err,
TryBadSyntax => hard_err,
TypeAnnotationNoClosingBracket | BracketedRefTypeNoClosingBracket => missing,