diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2020-02-28 14:20:33 +0100 |
|---|---|---|
| committer | Matthias Krüger <matthias.krueger@famsik.de> | 2020-02-28 15:16:27 +0100 |
| commit | 9523c89f18ca62c992e580fc33fe1bf092696d8d (patch) | |
| tree | fe98aa841d6ff82631ffc933c6f632f16e96546f /src/librustc_data_structures | |
| parent | e2223c94bf433fc38234d1303e88cbaf14755863 (diff) | |
| download | rust-9523c89f18ca62c992e580fc33fe1bf092696d8d.tar.gz rust-9523c89f18ca62c992e580fc33fe1bf092696d8d.zip | |
use is_empty() instead of len() == x to determine if structs are empty.
Diffstat (limited to 'src/librustc_data_structures')
| -rw-r--r-- | src/librustc_data_structures/profiling.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_data_structures/profiling.rs b/src/librustc_data_structures/profiling.rs index f2c80510f22..a70314c35c0 100644 --- a/src/librustc_data_structures/profiling.rs +++ b/src/librustc_data_structures/profiling.rs @@ -425,7 +425,7 @@ impl SelfProfiler { } // Warn about any unknown event names - if unknown_events.len() > 0 { + if !unknown_events.is_empty() { unknown_events.sort(); unknown_events.dedup(); |
