[][src]Trait rustc_middle::ty::codec::TyDecoder

pub trait TyDecoder<'tcx>: Decoder {
    const CLEAR_CROSS_CRATE: bool;

    fn tcx(&self) -> TyCtxt<'tcx>;
fn peek_byte(&self) -> u8;
fn position(&self) -> usize;
fn cached_ty_for_shorthand<F>(
        &mut self,
        shorthand: usize,
        or_insert_with: F
    ) -> Result<Ty<'tcx>, Self::Error>
    where
        F: FnOnce(&mut Self) -> Result<Ty<'tcx>, Self::Error>
;
fn with_position<F, R>(&mut self, pos: usize, f: F) -> R
    where
        F: FnOnce(&mut Self) -> R
;
fn map_encoded_cnum_to_current(&self, cnum: CrateNum) -> CrateNum;
fn decode_alloc_id(&mut self) -> Result<AllocId, Self::Error>; fn positioned_at_shorthand(&self) -> bool { ... } }

Associated Constants

const CLEAR_CROSS_CRATE: bool

Loading content...

Required methods

fn tcx(&self) -> TyCtxt<'tcx>

fn peek_byte(&self) -> u8

fn position(&self) -> usize

fn cached_ty_for_shorthand<F>(
    &mut self,
    shorthand: usize,
    or_insert_with: F
) -> Result<Ty<'tcx>, Self::Error> where
    F: FnOnce(&mut Self) -> Result<Ty<'tcx>, Self::Error>, 

fn with_position<F, R>(&mut self, pos: usize, f: F) -> R where
    F: FnOnce(&mut Self) -> R, 

fn map_encoded_cnum_to_current(&self, cnum: CrateNum) -> CrateNum

fn decode_alloc_id(&mut self) -> Result<AllocId, Self::Error>

Loading content...

Provided methods

fn positioned_at_shorthand(&self) -> bool

Loading content...

Implementors

impl<'a, 'tcx> TyDecoder<'tcx> for CacheDecoder<'a, 'tcx>[src]

Loading content...