File tree 5 files changed +5
-1955
lines changed
compiler/rustc_data_structures/src
5 files changed +5
-1955
lines changed Original file line number Diff line number Diff line change 26
26
#![ feature( test) ]
27
27
#![ feature( thread_id_value) ]
28
28
#![ feature( vec_into_raw_parts) ]
29
+ #![ feature( ptr_sub_ptr) ]
29
30
#![ allow( rustc:: default_hash_types) ]
30
31
#![ allow( rustc:: potential_query_instability) ]
31
32
@@ -76,7 +77,6 @@ pub mod jobserver;
76
77
pub mod macros;
77
78
pub mod map_in_place;
78
79
pub mod obligation_forest;
79
- pub mod owning_ref;
80
80
pub mod sip128;
81
81
pub mod small_c_str;
82
82
pub mod small_str;
@@ -103,6 +103,7 @@ pub mod vec_map;
103
103
pub mod work_queue;
104
104
pub use atomic_ref:: AtomicRef ;
105
105
pub mod frozen;
106
+ pub mod owned_slice;
106
107
pub mod sso;
107
108
pub mod steal;
108
109
pub mod tagged_ptr;
Original file line number Diff line number Diff line change @@ -2,9 +2,10 @@ use std::fs::File;
2
2
use std:: io;
3
3
use std:: ops:: Deref ;
4
4
5
- use crate :: owning_ref:: StableAddress ;
5
+ // FIXME(nilstrieb): This was created to implement owning_ref::StableAddress.
6
+ // Since owning_ref has been deleted, this can be removed as well.
6
7
7
- /// A trivial wrapper for [`memmap2::Mmap`] that implements [` StableAddress`] .
8
+ /// A trivial wrapper for [`memmap2::Mmap`] that implements owning_ref:: StableAddress.
8
9
#[ cfg( not( target_arch = "wasm32" ) ) ]
9
10
pub struct Mmap ( memmap2:: Mmap ) ;
10
11
@@ -39,9 +40,3 @@ impl Deref for Mmap {
39
40
& * self . 0
40
41
}
41
42
}
42
-
43
- // SAFETY: On architectures other than WASM, mmap is used as backing storage. The address of this
44
- // memory map is stable. On WASM, `Vec<u8>` is used as backing storage. The `Mmap` type doesn't
45
- // export any function that can cause the `Vec` to be re-allocated. As such the address of the
46
- // bytes inside this `Vec` is stable.
47
- unsafe impl StableAddress for Mmap { }
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments