Clippy code cleanup

This commit is contained in:
2026-08-15 13:22:59 +03:00
parent 9917702c4c
commit e676898135
22 changed files with 290 additions and 171 deletions
+5 -5
View File
@@ -97,18 +97,18 @@ impl WritingState {
}
if self.show_all {
if self.set.is_empty() == false && self.kana_total.is_empty() == false {
if !self.set.is_empty() && !self.kana_total.is_empty() {
self.set.clear();
}
for pair in &self.set {
self.kana = "---".to_string();
self.roman_total += &*format!("{} ", &pair.1.clone()).to_string();
self.kana_total += &*format!("{} ", &pair.0).to_string();
self.roman_total += &*format!("{} ", pair.1.clone()).to_string();
self.kana_total += &*format!("{} ", pair.0).to_string();
}
} else {
let current = self.set.pop().unwrap();
self.kana_total += &*format!("{} ", &current.0).to_string();
self.roman_total += &*format!("{} ", &current.1.clone()).to_string();
self.kana_total += &*format!("{} ", current.0).to_string();
self.roman_total += &*format!("{} ", current.1.clone()).to_string();
self.kana = current.1;
}
}