# AddRange

> Adds elements from a buffer to this list.

## Definition

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

## AddRange(void\*, int)

Adds elements from a buffer to this list.

```csharp
public void AddRange(void* ptr, int length)
```

### Parameters

**** (\[void\*]\(https\://learn.microsoft.com/dotnet/api/system.void)): A pointer to the buffer.**** (\[int]\(https\://learn.microsoft.com/dotnet/api/system.int32)): The number of elements to add to the list.

## AddRange(UnsafePtrList\<T>)

Copies the elements of another list to the end of this list.

```csharp
public void AddRange(UnsafePtrList<T> list)
```

### Parameters

**** (\[UnsafePtrList\<T>]\(/engine/6000.7/script-reference/unity/collections/lowlevel/unsafe/unsafeptrlist1)): The other list to copy from.

### Remarks

Increments the length by the length of the other list. Increases the capacity if necessary.
