---
title: arrayLength
framework: metal
role: symbol
role_heading: Instance Property
path: metal/mtlargumentdescriptor/arraylength
---

# arrayLength

The length of an array argument.

## Declaration

```swift
var arrayLength: Int { get set }
```

## Discussion

Discussion For a nonarray argument, this value needs to be 0.

## See Also

### Setting the descriptor’s properties

- [dataType](metal/mtlargumentdescriptor/datatype.md)
- [index](metal/mtlargumentdescriptor/index.md)
- [access](metal/mtlargumentdescriptor/access.md)
- [constantBlockAlignment](metal/mtlargumentdescriptor/constantblockalignment.md)
- [textureType](metal/mtlargumentdescriptor/texturetype.md)
