pub trait Decodable<D: Decoder>: Sized {
    fn decode(d: &mut D) -> Self;
}
Expand description

Trait for types that can be deserialized

This can be implemented using the Decodable, TyDecodable and MetadataDecodable macros.

  • Decodable should be used in crates that don’t depend on rustc_middle.
  • MetadataDecodable is used in rustc_metadata for types that contain rustc_metadata::rmeta::Lazy.
  • TyDecodable should be used for types that are only serialized in crate metadata or the incremental cache. This is most types in rustc_middle.

Required Methods

Implementations on Foreign Types

Implementors