Module rustc_middle::ty::codec

source ·
Expand description

This module contains some shared code for encoding and decoding various things from the ty module, and in particular implements support for “shorthands” which allow to have pointers back into the already encoded stream instead of re-encoding the same thing twice.

The functionality in here is shared between persisting to crate metadata and persisting to incr. comp. caches.

Macros§

Constants§

  • The shorthand encoding uses an enum’s variant index usize and is offset by this value so it never matches a real variant. This offset is also chosen so that the first byte is never < 0x80.

Traits§

Functions§