mirror of
https://github.com/astral-sh/ruff
synced 2026-01-21 21:40:51 -05:00
Use backticks for pep8-naming messages
This commit is contained in:
@@ -1213,19 +1213,19 @@ impl CheckKind {
|
||||
CheckKind::NoOverIndentation => "Docstring is over-indented".to_string(),
|
||||
// pep8-naming
|
||||
CheckKind::InvalidClassName(name) => {
|
||||
format!("class name '{name}' should use CapWords convention ")
|
||||
format!("class name `{name}` should use CapWords convention ")
|
||||
}
|
||||
CheckKind::InvalidFunctionName(name) => {
|
||||
format!("function name '{name}' should be lowercase")
|
||||
format!("function name `{name}` should be lowercase")
|
||||
}
|
||||
CheckKind::InvalidArgumentName(name) => {
|
||||
format!("argument name '{name}' should be lowercase")
|
||||
format!("argument name `{name}` should be lowercase")
|
||||
}
|
||||
CheckKind::InvalidFirstArgumentNameForClassMethod => {
|
||||
"first argument of a classmethod should be named 'cls'".to_string()
|
||||
"first argument of a classmethod should be named `cls`".to_string()
|
||||
}
|
||||
CheckKind::InvalidFirstArgumentNameForMethod => {
|
||||
"first argument of a method should be named 'self'".to_string()
|
||||
"first argument of a method should be named `self`".to_string()
|
||||
}
|
||||
// Meta
|
||||
CheckKind::UnusedNOQA(codes) => match codes {
|
||||
|
||||
Reference in New Issue
Block a user