From 0038eaee6b44b9828334bf93e220a3aa3c43402c Mon Sep 17 00:00:00 2001 From: Vadim Petrochenkov <vadim.petrochenkov@gmail.com> Date: Sun, 14 Feb 2021 18:56:21 +0300 Subject: [PATCH] rustc_span: Remove obsolete `allow_internal_unstable_backcompat_hack` --- compiler/rustc_span/src/lib.rs | 9 ++++----- compiler/rustc_span/src/symbol.rs | 1 - 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/compiler/rustc_span/src/lib.rs b/compiler/rustc_span/src/lib.rs index 79c5c7f110c..4b03d38ccba 100644 --- a/compiler/rustc_span/src/lib.rs +++ b/compiler/rustc_span/src/lib.rs @@ -510,11 +510,10 @@ impl Span { /// items can be used (that is, a macro marked with /// `#[allow_internal_unstable]`). pub fn allows_unstable(&self, feature: Symbol) -> bool { - self.ctxt().outer_expn_data().allow_internal_unstable.map_or(false, |features| { - features - .iter() - .any(|&f| f == feature || f == sym::allow_internal_unstable_backcompat_hack) - }) + self.ctxt() + .outer_expn_data() + .allow_internal_unstable + .map_or(false, |features| features.iter().any(|&f| f == feature)) } /// Checks if this span arises from a compiler desugaring of kind `kind`. diff --git a/compiler/rustc_span/src/symbol.rs b/compiler/rustc_span/src/symbol.rs index 1c37a6b2aca..0e6235c1676 100644 --- a/compiler/rustc_span/src/symbol.rs +++ b/compiler/rustc_span/src/symbol.rs @@ -252,7 +252,6 @@ symbols! { allow_fail, allow_internal_unsafe, allow_internal_unstable, - allow_internal_unstable_backcompat_hack, allowed, always, and,