Skip to content

Commit 49e52e7

Browse files
committed
Remove unused types from rustc::mir::interpret
The types are no longer used with the change to stacked borrows for validation.
1 parent 2149d73 commit 49e52e7

File tree

2 files changed

+0
-38
lines changed

2 files changed

+0
-38
lines changed

src/librustc/ich/impls_ty.rs

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -473,22 +473,6 @@ impl_stable_hash_for!(enum mir::interpret::InboundsCheck {
473473
MaybeDead
474474
});
475475

476-
impl_stable_hash_for!(enum mir::interpret::Lock {
477-
NoLock,
478-
WriteLock(dl),
479-
ReadLock(v)
480-
});
481-
482-
impl_stable_hash_for!(struct mir::interpret::DynamicLifetime {
483-
frame,
484-
region
485-
});
486-
487-
impl_stable_hash_for!(enum mir::interpret::AccessKind {
488-
Read,
489-
Write
490-
});
491-
492476
impl_stable_hash_for!(enum ty::Variance {
493477
Covariant,
494478
Invariant,

src/librustc/mir/interpret/mod.rs

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ use mir;
2929
use hir::def_id::DefId;
3030
use ty::{self, TyCtxt, Instance};
3131
use ty::layout::{self, Size};
32-
use middle::region;
3332
use std::io;
3433
use rustc_serialize::{Encoder, Decodable, Encodable};
3534
use rustc_data_structures::fx::FxHashMap;
@@ -40,27 +39,6 @@ use ty::codec::TyDecoder;
4039
use std::sync::atomic::{AtomicU32, Ordering};
4140
use std::num::NonZeroU32;
4241

43-
#[derive(Clone, Debug, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
44-
pub enum Lock {
45-
NoLock,
46-
WriteLock(DynamicLifetime),
47-
/// This should never be empty -- that would be a read lock held and nobody
48-
/// there to release it...
49-
ReadLock(Vec<DynamicLifetime>),
50-
}
51-
52-
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash, RustcEncodable, RustcDecodable)]
53-
pub struct DynamicLifetime {
54-
pub frame: usize,
55-
pub region: Option<region::Scope>, // "None" indicates "until the function ends"
56-
}
57-
58-
#[derive(Copy, Clone, Debug, PartialEq, Eq, RustcEncodable, RustcDecodable)]
59-
pub enum AccessKind {
60-
Read,
61-
Write,
62-
}
63-
6442
/// Uniquely identifies a specific constant or static.
6543
#[derive(Copy, Clone, Debug, Eq, PartialEq, Hash, RustcEncodable, RustcDecodable)]
6644
pub struct GlobalId<'tcx> {

0 commit comments

Comments
 (0)