Trait rustc_ast_lowering::ResolverAstLowering[][src]

pub trait ResolverAstLowering {
Show 15 methods fn def_key(&mut self, id: DefId) -> DefKey;
fn def_span(&self, id: LocalDefId) -> Span;
fn item_generics_num_lifetimes(&self, def: DefId) -> usize;
fn legacy_const_generic_args(&mut self, expr: &Expr) -> Option<Vec<usize>>;
fn get_partial_res(&mut self, id: NodeId) -> Option<PartialRes>;
fn get_import_res(&mut self, id: NodeId) -> PerNS<Option<Res<NodeId>>>;
fn get_label_res(&mut self, id: NodeId) -> Option<NodeId>;
fn definitions(&mut self) -> &mut Definitions;
fn lint_buffer(&mut self) -> &mut LintBuffer;
fn next_node_id(&mut self) -> NodeId;
fn take_trait_map(&mut self) -> NodeMap<Vec<TraitCandidate>>;
fn opt_local_def_id(&self, node: NodeId) -> Option<LocalDefId>;
fn local_def_id(&self, node: NodeId) -> LocalDefId;
fn def_path_hash(&self, def_id: DefId) -> DefPathHash;
fn create_def(
        &mut self,
        parent: LocalDefId,
        node_id: NodeId,
        data: DefPathData,
        expn_id: ExpnId,
        span: Span
    ) -> LocalDefId;
}

Required methods

Obtains resolution for a NodeId with a single resolution.

Obtains per-namespace resolutions for use statement with the given NodeId.

Obtains resolution for a label with the given NodeId.

We must keep the set of definitions up to date as we add nodes that weren’t in the AST. This should only return None during testing.

Implementors