From 4ff583b1161c5c2e08c28a0740f34a526b39a8bc Mon Sep 17 00:00:00 2001 From: Alexis Beingessner Date: Tue, 4 Apr 2017 12:31:38 -0400 Subject: fallout from NonZero/Unique/Shared changes --- src/librustc_data_structures/array_vec.rs | 2 +- src/librustc_data_structures/obligation_forest/node_index.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/librustc_data_structures') diff --git a/src/librustc_data_structures/array_vec.rs b/src/librustc_data_structures/array_vec.rs index 848e5a076bb..078bb801751 100644 --- a/src/librustc_data_structures/array_vec.rs +++ b/src/librustc_data_structures/array_vec.rs @@ -255,7 +255,7 @@ impl<'a, A: Array> Drop for Drain<'a, A> { if self.tail_len > 0 { unsafe { - let source_array_vec = &mut *self.array_vec.as_mut_ptr(); + let source_array_vec = self.array_vec.as_mut(); // memmove back untouched tail, update to new length let start = source_array_vec.len(); let tail = self.tail_start; diff --git a/src/librustc_data_structures/obligation_forest/node_index.rs b/src/librustc_data_structures/obligation_forest/node_index.rs index 1063bb3611e..023c56ca59b 100644 --- a/src/librustc_data_structures/obligation_forest/node_index.rs +++ b/src/librustc_data_structures/obligation_forest/node_index.rs @@ -23,6 +23,6 @@ impl NodeIndex { } pub fn get(self) -> usize { - (*self.index - 1) as usize + (self.index.get() - 1) as usize } } -- cgit 1.4.1-3-g733a5