rustc: Move features
from Session
to GlobalCtxt
Removes two pieces of mutable state. Follow up to #114622.
This commit is contained in:
parent
a07bc13e14
commit
7353c96be8
30 changed files with 130 additions and 93 deletions
|
@ -31,10 +31,11 @@ pub(crate) fn expand(
|
|||
|
||||
pub(crate) fn cfg_eval(
|
||||
sess: &Session,
|
||||
features: Option<&Features>,
|
||||
features: &Features,
|
||||
annotatable: Annotatable,
|
||||
lint_node_id: NodeId,
|
||||
) -> Annotatable {
|
||||
let features = Some(features);
|
||||
CfgEval { cfg: &mut StripUnconfigured { sess, features, config_tokens: true, lint_node_id } }
|
||||
.configure_annotatable(annotatable)
|
||||
// Since the item itself has already been configured by the `InvocationCollector`,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue