Make thread utilities unsafe

This commit is contained in:
Yota Toyama
2019-04-15 15:30:14 +00:00
parent 1acd4e325e
commit 8f96257594
8 changed files with 16 additions and 16 deletions

View File

@@ -10,7 +10,7 @@ fn main() {
unsafe { Allocator::initialize() }
let handle = std::thread::spawn(move || {
Allocator::register_current_thread().unwrap();
unsafe { Allocator::register_current_thread().unwrap() }
let mut _n = unsafe { GLOBAL_ALLOCATOR.alloc(Layout::from_size_align(2 ^ 8, 8).unwrap()) };