mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-23 22:14:15 +00:00
Remove DepNodeIndexNew::new and ::index, they are already impl for Idx
This commit is contained in:
parent
0e6f4cf51c
commit
70c3a3da6d
@ -569,20 +569,6 @@ pub(super) struct DepNodeIndexNew {
|
||||
}
|
||||
|
||||
impl Idx for DepNodeIndexNew {
|
||||
fn new(idx: usize) -> Self {
|
||||
DepNodeIndexNew::new(idx)
|
||||
}
|
||||
fn index(self) -> usize {
|
||||
self.index()
|
||||
}
|
||||
}
|
||||
|
||||
impl DepNodeIndexNew {
|
||||
|
||||
const INVALID: DepNodeIndexNew = DepNodeIndexNew {
|
||||
index: ::std::u32::MAX,
|
||||
};
|
||||
|
||||
fn new(v: usize) -> DepNodeIndexNew {
|
||||
assert!((v & 0xFFFF_FFFF) == v);
|
||||
DepNodeIndexNew { index: v as u32 }
|
||||
@ -593,6 +579,12 @@ impl DepNodeIndexNew {
|
||||
}
|
||||
}
|
||||
|
||||
impl DepNodeIndexNew {
|
||||
const INVALID: DepNodeIndexNew = DepNodeIndexNew {
|
||||
index: ::std::u32::MAX,
|
||||
};
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, PartialEq)]
|
||||
enum OpenTask {
|
||||
Regular {
|
||||
|
Loading…
Reference in New Issue
Block a user