registerAllocator method
void
registerAllocator(
- String key,
- RaylibTempAllocatorBase<
RaylibTempBase< allocRaylibBase> , dynamic, dynamic>
Registers a custom allocator under key. Throws StateError if key is already taken.
Implementation
void registerAllocator(String key, RaylibTempAllocatorBase alloc) {
if (customAllocators.containsKey(key)) {
final sig = customAllocators[key]!.signature();
throw StateError("Allocator '$key' ('$sig') already exists!");
}
customAllocators[key] = alloc;
}