mirror of
https://github.com/vlang/v.git
synced 2025-09-18 11:56:57 -04:00
coroutines: fix dealloc (called wrong fn)
This commit is contained in:
parent
9604a3f491
commit
b3ac88efe5
@ -31,7 +31,7 @@ fn init() {
|
|||||||
}
|
}
|
||||||
dealloc := fn (_ voidptr, stack_ptr voidptr, stack_size int) {
|
dealloc := fn (_ voidptr, stack_ptr voidptr, stack_size int) {
|
||||||
unsafe {
|
unsafe {
|
||||||
C.GC_add_roots(stack_ptr, charptr(stack_ptr) + stack_size)
|
C.GC_remove_roots(stack_ptr, charptr(stack_ptr) + stack_size)
|
||||||
free(stack_ptr)
|
free(stack_ptr)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user