Remove unused types from rustc::mir::interpret

The types are no longer used with the change to stacked borrows for
validation.
This commit is contained in:
Matthew Jasper 2018-12-29 11:55:00 +00:00
parent 2149d73358
commit 49e52e71de
2 changed files with 0 additions and 38 deletions

View file

@ -473,22 +473,6 @@ impl_stable_hash_for!(enum mir::interpret::InboundsCheck {
MaybeDead
});
impl_stable_hash_for!(enum mir::interpret::Lock {
NoLock,
WriteLock(dl),
ReadLock(v)
});
impl_stable_hash_for!(struct mir::interpret::DynamicLifetime {
frame,
region
});
impl_stable_hash_for!(enum mir::interpret::AccessKind {
Read,
Write
});
impl_stable_hash_for!(enum ty::Variance {
Covariant,
Invariant,

View file

@ -29,7 +29,6 @@ use mir;
use hir::def_id::DefId;
use ty::{self, TyCtxt, Instance};
use ty::layout::{self, Size};
use middle::region;
use std::io;
use rustc_serialize::{Encoder, Decodable, Encodable};
use rustc_data_structures::fx::FxHashMap;
@ -40,27 +39,6 @@ use ty::codec::TyDecoder;
use std::sync::atomic::{AtomicU32, Ordering};
use std::num::NonZeroU32;
#[derive(Clone, Debug, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
pub enum Lock {
NoLock,
WriteLock(DynamicLifetime),
/// This should never be empty -- that would be a read lock held and nobody
/// there to release it...
ReadLock(Vec<DynamicLifetime>),
}
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
pub struct DynamicLifetime {
pub frame: usize,
pub region: Option<region::Scope>, // "None" indicates "until the function ends"
}
#[derive(Copy, Clone, Debug, PartialEq, Eq, RustcEncodable, RustcDecodable)]
pub enum AccessKind {
Read,
Write,
}
/// Uniquely identifies a specific constant or static.
#[derive(Copy, Clone, Debug, Eq, PartialEq, Hash, RustcEncodable, RustcDecodable)]
pub struct GlobalId<'tcx> {