mirror of https://github.com/astral-sh/ruff
Start with Upper case in error messages (#5045)
## Summary To be consistent with the format used by other errors. ## Test Plan N/A.
This commit is contained in:
parent
95ee6dcb3b
commit
e1fd3965a2
|
|
@ -231,11 +231,11 @@ impl Display for DisplayParseErrorType<'_> {
|
|||
if let Some(expected) = expected.as_ref() {
|
||||
write!(
|
||||
f,
|
||||
"expected '{expected}', but got {tok}",
|
||||
"Expected '{expected}', but got {tok}",
|
||||
tok = TruncateAtNewline(&tok)
|
||||
)
|
||||
} else {
|
||||
write!(f, "unexpected token {tok}", tok = TruncateAtNewline(&tok))
|
||||
write!(f, "Unexpected token {tok}", tok = TruncateAtNewline(&tok))
|
||||
}
|
||||
}
|
||||
ParseErrorType::Lexical(ref error) => write!(f, "{error}"),
|
||||
|
|
|
|||
Loading…
Reference in New Issue