diff options
| author | Matthias Krüger <matthias.krueger@famsik.de> | 2021-02-21 18:11:27 +0100 |
|---|---|---|
| committer | Matthias Krüger <matthias.krueger@famsik.de> | 2021-02-21 18:11:27 +0100 |
| commit | da9a588d4fda02c2fe6d52db651ec4c83b2b3e49 (patch) | |
| tree | 1fb08662196f74d9b0b011e138cf84cbdbdded30 /compiler/rustc_passes | |
| parent | a9b90c02a2aaa53881aa650d3792726135402403 (diff) | |
| download | rust-da9a588d4fda02c2fe6d52db651ec4c83b2b3e49.tar.gz rust-da9a588d4fda02c2fe6d52db651ec4c83b2b3e49.zip | |
remove redundant wrapping of return types of allow_internal_unstable() and rustc_allow_const_fn_unstable()
Diffstat (limited to 'compiler/rustc_passes')
| -rw-r--r-- | compiler/rustc_passes/src/check_const.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_passes/src/check_const.rs b/compiler/rustc_passes/src/check_const.rs index 9328f7cd9ec..da713566c31 100644 --- a/compiler/rustc_passes/src/check_const.rs +++ b/compiler/rustc_passes/src/check_const.rs @@ -106,7 +106,7 @@ impl<'tcx> CheckConstVisitor<'tcx> { // However, we cannot allow stable `const fn`s to use unstable features without an explicit // opt-in via `rustc_allow_const_fn_unstable`. attr::rustc_allow_const_fn_unstable(&tcx.sess, &tcx.get_attrs(def_id)) - .map_or(false, |mut features| features.any(|name| name == feature_gate)) + .any(|name| name == feature_gate) }; match required_gates { |
