Struct rustc::middle::expr_use_visitor::ExprUseVisitor
[−]
[src]
pub struct ExprUseVisitor<'a, 'gcx: 'a + 'tcx, 'tcx: 'a> { /* fields omitted */ }
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Methods
impl<'a, 'tcx> ExprUseVisitor<'a, 'tcx, 'tcx>
[src]
impl<'a, 'tcx> ExprUseVisitor<'a, 'tcx, 'tcx>
pub fn new(
delegate: &'a mut (Delegate<'tcx> + 'a),
tcx: TyCtxt<'a, 'tcx, 'tcx>,
param_env: ParamEnv<'tcx>,
region_scope_tree: &'a ScopeTree,
tables: &'a TypeckTables<'tcx>,
rvalue_promotable_map: Option<Lrc<ItemLocalSet>>
) -> Self
[src]
pub fn new(
delegate: &'a mut (Delegate<'tcx> + 'a),
tcx: TyCtxt<'a, 'tcx, 'tcx>,
param_env: ParamEnv<'tcx>,
region_scope_tree: &'a ScopeTree,
tables: &'a TypeckTables<'tcx>,
rvalue_promotable_map: Option<Lrc<ItemLocalSet>>
) -> Self
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Creates the ExprUseVisitor, configuring it with the various options provided:
delegate
-- who receives the callbacksparam_env
--- parameter environment for trait lookups (esp. pertaining toCopy
)region_scope_tree
--- region scope tree for the code being analyzedtables
--- typeck results for the code being analyzedrvalue_promotable_map
--- if you care about rvalue promotion, then provide the map here (it can be computed withtcx.rvalue_promotable_map(def_id)
).None
means that rvalues will be given more conservative lifetimes.
See also with_infer
, which is used during typeck.
impl<'a, 'gcx, 'tcx> ExprUseVisitor<'a, 'gcx, 'tcx>
[src]
impl<'a, 'gcx, 'tcx> ExprUseVisitor<'a, 'gcx, 'tcx>
pub fn with_infer(
delegate: &'a mut (Delegate<'tcx> + 'a),
infcx: &'a InferCtxt<'a, 'gcx, 'tcx>,
param_env: ParamEnv<'tcx>,
region_scope_tree: &'a ScopeTree,
tables: &'a TypeckTables<'tcx>
) -> Self
[src]
pub fn with_infer(
delegate: &'a mut (Delegate<'tcx> + 'a),
infcx: &'a InferCtxt<'a, 'gcx, 'tcx>,
param_env: ParamEnv<'tcx>,
region_scope_tree: &'a ScopeTree,
tables: &'a TypeckTables<'tcx>
) -> Self
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn consume_body(&mut self, body: &Body)
[src]
pub fn consume_body(&mut self, body: &Body)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn consume_expr(&mut self, expr: &Expr)
[src]
pub fn consume_expr(&mut self, expr: &Expr)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
pub fn walk_expr(&mut self, expr: &Expr)
[src]
pub fn walk_expr(&mut self, expr: &Expr)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Trait Implementations
Auto Trait Implementations
impl<'a, 'gcx, 'tcx> !Send for ExprUseVisitor<'a, 'gcx, 'tcx>
impl<'a, 'gcx, 'tcx> !Send for ExprUseVisitor<'a, 'gcx, 'tcx>
impl<'a, 'gcx, 'tcx> !Sync for ExprUseVisitor<'a, 'gcx, 'tcx>
impl<'a, 'gcx, 'tcx> !Sync for ExprUseVisitor<'a, 'gcx, 'tcx>