mirror of https://github.com/astral-sh/ruff
Use file-specific quote for C408 (#3128)
This commit is contained in:
parent
817d0b4902
commit
df3932f750
|
|
@ -522,11 +522,13 @@ pub fn fix_unnecessary_collection_call(
|
||||||
// Quote each argument.
|
// Quote each argument.
|
||||||
for arg in &call.args {
|
for arg in &call.args {
|
||||||
let quoted = format!(
|
let quoted = format!(
|
||||||
"\"{}\"",
|
"{}{}{}",
|
||||||
|
stylist.quote(),
|
||||||
arg.keyword
|
arg.keyword
|
||||||
.as_ref()
|
.as_ref()
|
||||||
.expect("Expected dictionary argument to be kwarg")
|
.expect("Expected dictionary argument to be kwarg")
|
||||||
.value
|
.value,
|
||||||
|
stylist.quote(),
|
||||||
);
|
);
|
||||||
arena.push(quoted);
|
arena.push(quoted);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue