Expand description
Memory arena allocator used by all other submodules.
See the oxc_allocator module-level documentation for more information.
Modules§
- hash_
map - A hash map without
Dropthat stores data in arena allocator. - hash_
set - A hash set without
Dropthat stores data in arena allocator. - ident_
hasher - A custom hasher for
Identkeys with precomputed hashes.
Structs§
- Address
- Memory address of an AST node in arena.
- Allocator
- A bump-allocated memory arena.
- Arena
Box - A
BoxwithoutDrop, which stores its data in the arena allocator. - Arena
Hash Map - A hash map without
Dropthat stores data in arena allocator. - Arena
Hash Set - A hash set without
Dropthat stores data in arena allocator. - Arena
String Builder - String builder.
- Arena
Vec - A
VecwithoutDrop, which stores its data in the arena allocator. - BitSet
- A bitset allocated in an arena.
- Box
- A
BoxwithoutDrop, which stores its data in the arena allocator. - HashMap
- A hash map without
Dropthat stores data in arena allocator. - HashSet
- A hash set without
Dropthat stores data in arena allocator. - Ident
Build Hasher - A
BuildHasherforIdent-keyed hash maps. - String
Builder - String builder.
- Vec
- A
VecwithoutDrop, which stores its data in the arena allocator.
Traits§
- CloneIn
- A trait to explicitly clone an object into an arena allocator.
- Dummy
- A trait to create a dummy AST node.
- FromIn
- This trait works similarly to the standard library
Fromtrait. - GetAddress
- Trait for getting the memory address of an AST node.
- GetAllocator
- Accessor for getting the underlying allocator.
- IntoIn
- This trait works similarly to the standard library
Intotrait. It is similar toFromInis reflective, AFromInimplementation also implicitly implementsIntoInfor the opposite type. - Replace
With - A trait to replace an existing AST node in place with a new node built from the old one.
- TakeIn
- A trait to replace an existing AST node with a dummy.
- Unstable
Address - Trait for getting the memory address of an AST node which is not necessarily stable.
Functions§
- ident_
hash - Compute a fast, high-quality hash of identifier bytes.
- pack_
len_ hash - Pack length and hash into a single
u64.