diff options
author | Yuri Astrakhan <yuriastrakhan@gmail.com> | 2023-11-15 03:47:22 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-15 03:47:22 -0500 |
commit | 5eb4fbde5d7e41cd39dcb7c95e1bbf542e706cb0 (patch) | |
tree | 13b0ba47b78190b294b54d05eb4821306a6687f3 /src/canvas/widgets/basic_table_arrows.rs | |
parent | a6200640b9a074feb116b7808543c8cb73c8dd30 (diff) |
chore: fix certain uninlined string format uses (#1310)
* Fixed uninlined args
First ran this, and fixed a few more similar issues by hand
```
cargo clippy --workspace --fix --benches --tests --bins -- -A clippy::all -W clippy::uninlined_format_args
```
Note that in a few cases, format args were passed by ref - which is actually a tiny perf hit - compiler would not be able to optimize them.
* revert change here
since it contains a non-inlineable variable I'm not a fan of using it partially here
* revert
given the other formats above/below I would prefer keeping it like this
---------
Co-authored-by: Clement Tsang <34804052+ClementTsang@users.noreply.github.com>
Diffstat (limited to 'src/canvas/widgets/basic_table_arrows.rs')
-rw-r--r-- | src/canvas/widgets/basic_table_arrows.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/canvas/widgets/basic_table_arrows.rs b/src/canvas/widgets/basic_table_arrows.rs index 029a6e12..addd5207 100644 --- a/src/canvas/widgets/basic_table_arrows.rs +++ b/src/canvas/widgets/basic_table_arrows.rs @@ -95,7 +95,7 @@ impl Painter { let left_arrow_text = vec![ Line::default(), Line::from(Span::styled( - format!("◄ {}", left_name), + format!("◄ {left_name}"), self.colours.text_style, )), ]; @@ -103,7 +103,7 @@ impl Painter { let right_arrow_text = vec![ Line::default(), Line::from(Span::styled( - format!("{} ►", right_name), + format!("{right_name} ►"), self.colours.text_style, )), ]; |