mirror of
https://github.com/astral-sh/ruff.git
synced 2025-08-30 23:27:38 +00:00
[minor] Simplify some ExprStringLiteral
creation logic (#15775)
This commit is contained in:
parent
9bf138c45a
commit
9c938442e5
3 changed files with 12 additions and 18 deletions
|
@ -79,7 +79,7 @@ impl Transformer for Normalizer {
|
|||
|
||||
if can_join {
|
||||
string.value = ast::StringLiteralValue::single(ast::StringLiteral {
|
||||
value: string.value.to_str().to_string().into_boxed_str(),
|
||||
value: Box::from(string.value.to_str()),
|
||||
range: string.range,
|
||||
flags: StringLiteralFlags::empty(),
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue