⚓ Oxc Memory Allocator
Oxc uses a bump-based memory arena for faster AST allocations. This crate
contains an [Allocator
] for creating such arenas, as well as ports of
memory management data types from std
adapted to use this arena.
No Drop
s
Objects allocated into oxc memory arenas are never Dropped
, making
it relatively easy to leak memory if you're not careful. Memory is released
in bulk when the allocator is dropped.
Examples
use ;
let allocator = default;
let foo = Box new_in;
drop;
Consumers of the oxc
umbrella crate pass
[Allocator
] references to other tools.
use ;
let allocator = default
let parsed = new;
assert!;