diff options
| author | est31 <MTest31@outlook.com> | 2022-02-02 16:08:05 +0100 |
|---|---|---|
| committer | est31 <MTest31@outlook.com> | 2022-02-02 16:10:16 +0100 |
| commit | 08be313febc8146a3a8f57d46b33602bdbd1d30e (patch) | |
| tree | 0aad061a80e47df11604e08c9bd4521d3bf5d508 /compiler/rustc_query_system | |
| parent | d5f9c40e6a9ecc62432e71e886cef83a4c2c9b98 (diff) | |
| download | rust-08be313febc8146a3a8f57d46b33602bdbd1d30e.tar.gz rust-08be313febc8146a3a8f57d46b33602bdbd1d30e.zip | |
Use Option::then in two places
Diffstat (limited to 'compiler/rustc_query_system')
| -rw-r--r-- | compiler/rustc_query_system/src/dep_graph/serialized.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_query_system/src/dep_graph/serialized.rs b/compiler/rustc_query_system/src/dep_graph/serialized.rs index 283eda7c85e..c95dff13d66 100644 --- a/compiler/rustc_query_system/src/dep_graph/serialized.rs +++ b/compiler/rustc_query_system/src/dep_graph/serialized.rs @@ -182,7 +182,7 @@ impl<K: DepKind> EncoderState<K> { total_edge_count: 0, total_node_count: 0, result: Ok(()), - stats: if record_stats { Some(FxHashMap::default()) } else { None }, + stats: record_stats.then(FxHashMap::default), } } |
