Back to Sparse Direct Solver (SuperLU)
slu.core.withAllocations
RAII-style resource management.
Syntax
slu.core.withAllocations(module, allocations, fn)
Description
RAII-style resource management. Executes a function with allocated resources and ensures cleanup.
Parameters
| Name | Description |
|---|---|
| module | - SuperLU WASM module |
| allocations | - Object mapping names to allocation functions |
| fn | - Function to execute with allocated pointers |
Returns
Promise<T>