[][src]Trait rustc::dep_graph::safe::DepGraphSafe

pub trait DepGraphSafe { }
⚙️ This is an internal compiler API. (rustc_private)

This crate is being loaded from the sysroot, a permanently unstable location for private compiler dependencies. It is not intended for general use. Prefer using a public version of this crate from crates.io via Cargo.toml.

The DepGraphSafe trait is used to specify what kinds of values are safe to "leak" into a task. The idea is that this should be only be implemented for things like the tcx as well as various id types, which will create reads in the dep-graph whenever the trait loads anything that might depend on the input program.

Implementations on Foreign Types

impl DepGraphSafe for BodyId[src]

A BodyId on its own doesn't give access to any particular state. You must fetch the state from the various maps or generate on-demand queries, all of which create reads.

impl DepGraphSafe for NodeId[src]

A NodeId on its own doesn't give access to any particular state. You must fetch the state from the various maps or generate on-demand queries, all of which create reads.

impl DepGraphSafe for DefId[src]

A DefId on its own doesn't give access to any particular state. You must fetch the state from the various maps or generate on-demand queries, all of which create reads.

impl<A, B> DepGraphSafe for (A, B) where
    A: DepGraphSafe,
    B: DepGraphSafe
[src]

Tuples make it easy to build up state.

impl<'a, A> DepGraphSafe for &'a A where
    A: DepGraphSafe
[src]

Shared ref to dep-graph-safe stuff should still be dep-graph-safe.

impl<'a, A> DepGraphSafe for &'a mut A where
    A: DepGraphSafe
[src]

Mut ref to dep-graph-safe stuff should still be dep-graph-safe.

impl DepGraphSafe for ()[src]

No data here! :)

Loading content...

Implementors

impl<'a> DepGraphSafe for StableHashingContext<'a>[src]

impl<'tcx> DepGraphSafe for TyCtxt<'tcx>[src]

The type context itself can be used to access all kinds of tracked state, but those accesses should always generate read events.

impl<T> DepGraphSafe for AssertDepGraphSafe<T>[src]

Loading content...