Make Formatter Happy
Continuous Integration / Grammar Tests (push) Failing after 5s
Continuous Integration / Library Tests (push) Failing after 5s
Continuous Integration / Library Format Tests (push) Failing after 6s

Signed-off-by: Will Hawkins <hawkinsw@obs.cr>
This commit is contained in:
Will Hawkins
2026-05-04 22:25:51 -04:00
parent 7a36ca32dd
commit dd0bbbe479
3 changed files with 19 additions and 16 deletions
+1 -1
View File
@@ -70,7 +70,7 @@ public struct ErrorWithLocation: Errorable, Equatable, CustomStringConvertible {
public struct Errors: Errorable, CustomStringConvertible {
public func format(_ formatter: any Formattable) -> String {
self.errors.map() { error in
self.errors.map { error in
error.format(formatter)
}.joined(separator: "\n")
}
+12 -10
View File
@@ -169,11 +169,12 @@ public struct Parser {
current_context = updated_context
parsed_s.append(parsed_statement)
case .Error(let e):
errors = if let errors = errors {
errors.append(error: e)
} else {
e
}
errors =
if let errors = errors {
errors.append(error: e)
} else {
e
}
}
}
@@ -255,11 +256,12 @@ public struct Parser {
parsed_s = state_statements
current_context = updated_context
case .Error(let error):
errors = if let errors = errors {
errors.append(error: error)
} else {
error
}
errors =
if let errors = errors {
errors.append(error: error)
} else {
error
}
}
walker.next()
}
+6 -5
View File
@@ -90,11 +90,12 @@ public struct Program {
break
case .Error(let e):
found_parser = true
errors = if let errors = errors {
errors.append(error: e)
} else {
e
}
errors =
if let errors = errors {
errors.append(error: e)
} else {
e
}
break
}
}