pub mod default_alloc;
pub mod no_gc_alloc;
use xjbutil::flex::FlexArray;
use crate::data::Value;
use crate::vm::al31f::stack::Stack;
pub type AllocPin = FlexArray<bool, Value>;
pub trait Alloc: 'static + Send + Sync {
unsafe fn add_stack(&mut self, stack: *const Stack);
unsafe fn remove_stack(&mut self, stack: *const Stack);
unsafe fn add_managed(&mut self, data: Value);
unsafe fn mark_object(&mut self, data: Value);
unsafe fn pin_objects(&mut self, pinned: &[Value]) -> *mut bool;
unsafe fn collect(&mut self);
fn set_gc_allowed(&mut self, allowed: bool);
}