Enable clippy::useless_conversion
(#8767)
This PR enables the [`clippy::useless_conversion`](https://rust-lang.github.io/rust-clippy/master/index.html#/useless_conversion) rule and fixes the outstanding violations. Release Notes: - N/A
This commit is contained in:
parent
20d133322a
commit
fe04f69caf
30 changed files with 53 additions and 66 deletions
|
@ -979,7 +979,7 @@ impl AssistantPanel {
|
|||
font_size: rems(0.875).into(),
|
||||
font_weight: FontWeight::NORMAL,
|
||||
font_style: FontStyle::Normal,
|
||||
line_height: relative(1.3).into(),
|
||||
line_height: relative(1.3),
|
||||
background_color: None,
|
||||
underline: None,
|
||||
strikethrough: None,
|
||||
|
@ -1633,7 +1633,6 @@ impl Conversation {
|
|||
fn count_remaining_tokens(&mut self, cx: &mut ModelContext<Self>) {
|
||||
let messages = self
|
||||
.messages(cx)
|
||||
.into_iter()
|
||||
.map(|message| tiktoken_rs::ChatCompletionRequestMessage {
|
||||
role: match message.role {
|
||||
Role::User => "user".into(),
|
||||
|
@ -3199,7 +3198,7 @@ impl InlineAssistant {
|
|||
font_size: rems(0.875).into(),
|
||||
font_weight: FontWeight::NORMAL,
|
||||
font_style: FontStyle::Normal,
|
||||
line_height: relative(1.3).into(),
|
||||
line_height: relative(1.3),
|
||||
background_color: None,
|
||||
underline: None,
|
||||
strikethrough: None,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue