Skip to content

Commit f379c25

Browse files
committed
fix: clippy warnings (for_kv_map, saturating_sub)
1 parent 99cc325 commit f379c25

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

src/mcp/server.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3670,7 +3670,7 @@ impl McpServer {
36703670
let mut by_lang: HashMap<String, usize> = HashMap::new();
36713671
let mut by_type: HashMap<String, usize> = HashMap::new();
36723672
let mut total = 0usize;
3673-
for (_gn, graph) in &self.graphs {
3673+
for graph in self.graphs.values() {
36743674
for unit in graph.units() {
36753675
if !languages.is_empty()
36763676
&& !languages

src/temporal/archaeology.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ impl<'g> CodeArchaeologist<'g> {
195195

196196
let oldest = self.history.oldest_timestamp(&unit.file_path);
197197
let latest = self.history.latest_timestamp(&unit.file_path);
198-
let age_seconds = if latest > oldest { latest - oldest } else { 0 };
198+
let age_seconds = latest.saturating_sub(oldest);
199199

200200
// Infer evolution phase
201201
let phase = self.infer_phase(

0 commit comments

Comments
 (0)