Experimenting with the LSP

This commit is contained in:
Mia
2026-03-08 14:34:12 +01:00
parent 2aababbbe1
commit 45fd421e19
16 changed files with 1682 additions and 228 deletions
+6
View File
@@ -57,6 +57,12 @@ pub struct SyncArenaAllocator {
allocations: Vec<AllocationEntry>,
}
impl SyncArenaAllocator {
pub fn reset(&mut self) {
self.bump.lock().unwrap().reset();
}
}
impl Allocator for SyncArenaAllocator {
unsafe fn alloc_unsafe(&self, data: *const u8, layout: Layout, drop_fn: DropFn) -> *mut u8 {
unsafe {