Fix clippy warnings.

This commit fixes the current set of (stable) clippy warnings in the repo.
This commit is contained in:
Peter Huene
2019-10-23 23:15:42 -07:00
committed by Andrew Brown
parent 1176e4f178
commit 9f506692c2
93 changed files with 667 additions and 662 deletions

View File

@@ -5,7 +5,7 @@ use crate::srcgen::Formatter;
use cranelift_entity::EntityRef;
fn gen_regbank(fmt: &mut Formatter, reg_bank: &RegBank) {
let names = if reg_bank.names.len() > 0 {
let names = if !reg_bank.names.is_empty() {
format!(r#""{}""#, reg_bank.names.join(r#"", ""#))
} else {
"".to_string()