mirror of
https://github.com/bdwgc/bdwgc-rust.git
synced 2026-10-25 09:23:18 -06:00
Refactor coroutines example
This commit is contained in:
1 parent
05ac86223a
commit
3847afbc60
1 file changed
+2
-4
@@ -9,10 +9,8 @@ use std::alloc::{GlobalAlloc, Layout};
|
||||
static GLOBAL_ALLOCATOR: Allocator = Allocator;
|
||||
|
||||
fn main() {
|
||||
unsafe {
|
||||
Allocator::initialize();
|
||||
Allocator::disable_gc();
|
||||
}
|
||||
unsafe { Allocator::initialize() }
|
||||
Allocator::disable_gc();
|
||||
|
||||
let handle = Coroutine::spawn(move |_, _| {
|
||||
let bottom: u8 = 0;
|
||||
|
||||
Reference in new issue
Block a user