Use is_empty() instead of comparing len() with 0.

This commit is contained in:
Dan Gohman
2017-11-08 10:40:58 -08:00
parent 5d3ae0596c
commit d939bc5137

View File

@@ -991,7 +991,7 @@ impl<'a> Verifier<'a> {
self.func.dfg.ctrl_typevar(inst),
)
{
if possible_encodings.len() != 0 {
if !possible_encodings.is_empty() {
possible_encodings.push_str(", ");
multiple_encodings = true;
}