# Dispose()

> Dispose the custom allocator backing memory and unregister it.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Collections](/engine/6000.7/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.ManagedKernelModule

```csharp
[ExcludeFromBurstCompatTesting("DestroyAllocator is unburstable")]
public void Dispose()
```
