pub type ProvidedValue<'tcx> = ShallowLintLevelMap;
Expand description

This type alias specifies the type returned from query providers and the type used for decoding. For regular queries this is the declared returned type V, but arena_cache will use <V as Deref>::Target instead.

Implementations§

source§

impl ShallowLintLevelMap

source

fn probe_for_lint_level( &self, tcx: TyCtxt<'_>, id: LintId, start: HirId ) -> (Option<Level>, LintLevelSource)

Perform a deep probe in the HIR tree looking for the actual level for the lint. This lint level is not usable for diagnostics, it needs to be corrected by reveal_actual_level beforehand.

source

pub fn lint_level_id_at_node( &self, tcx: TyCtxt<'_>, lint: LintId, cur: HirId ) -> (Level, LintLevelSource)

Fetch and return the user-visible lint level for the given lint at the given HirId.

Trait Implementations§

source§

impl Debug for ShallowLintLevelMap

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for ShallowLintLevelMap

source§

fn default() -> ShallowLintLevelMap

Returns the “default value” for a type. Read more
source§

impl<'__ctx> HashStable<StableHashingContext<'__ctx>> for ShallowLintLevelMap

source§

fn hash_stable( &self, __hcx: &mut StableHashingContext<'__ctx>, __hasher: &mut StableHasher )

Layout§

Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference’s “Type Layout” chapter for details on type layout guarantees.

Size:24 bytes