Skip to content

Commit dd2be46

Browse files
MamunC0derorizi
andauthored
refactor: simplify redundant string conversions (#8675)
Co-authored-by: Ori Ziv <[email protected]> Co-authored-by: orizi <[email protected]>
1 parent a76f05b commit dd2be46

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

crates/cairo-lang-parser/src/colored_printer.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,7 @@ impl ColoredPrinter<'_> {
1818
if self.verbose && node.kind == SyntaxKind::TokenMissing {
1919
self.result.push_str(format!("{}", "<m>".red()).as_str());
2020
} else {
21-
self.result
22-
.push_str(set_color(text.long(self.db), node.kind).to_string().as_str());
21+
self.result.push_str(&set_color(text.long(self.db), node.kind).to_string());
2322
}
2423
}
2524
GreenNodeDetails::Node { .. } => {

0 commit comments

Comments
 (0)