clippy fixes

Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
William Casarin
2025-03-25 19:35:10 -07:00
parent 0b4807f62d
commit 80f02d829a
2 changed files with 7 additions and 7 deletions

View File

@@ -366,9 +366,9 @@ fn fs_main(in: VertexOutput) -> @location(0) vec4<f32> {
#[inline]
fn apply_friction(val: f32, friction: f32, clamp: f32) -> f32 {
if val < clamp {
return 0.0;
0.0
} else {
return val * friction;
val * friction
}
}

View File

@@ -266,7 +266,7 @@ impl SearchCall {
.limit(limit as u64)
.build();
let notes = {
if let Ok(results) = ndb.query(&txn, &[filter], limit) {
if let Ok(results) = ndb.query(txn, &[filter], limit) {
results.into_iter().map(|r| r.note_key.as_u64()).collect()
} else {
vec![]
@@ -395,7 +395,7 @@ impl Dave {
// have a debug option to show this
}
Message::ToolCalls(toolcalls) => {
Self::tool_call_ui(&toolcalls, ui);
Self::tool_call_ui(toolcalls, ui);
}
}
}
@@ -526,7 +526,7 @@ impl Dave {
entry
.arguments
.get_or_insert_with(String::new)
.push_str(&argchunk);
.push_str(argchunk);
}
}
}
@@ -539,7 +539,7 @@ impl Dave {
}
let mut parsed_tool_calls = vec![];
for (_index, partial) in &all_tool_calls {
for (_index, partial) in all_tool_calls {
let Some(unknown_tool_call) = partial.complete() else {
tracing::error!("could not complete partial tool call: {:?}", partial);
continue;
@@ -652,7 +652,7 @@ impl Tool {
"enum".to_string(),
Value::Array(
enums
.into_iter()
.iter()
.map(|s| Value::String((*s).to_owned()))
.collect(),
),