---
title: MutableSpan
framework: swift
role: symbol
role_heading: Structure
path: swift/mutablespan
---

# MutableSpan

## Declaration

```swift
@frozen struct MutableSpan<Element> where Element : ~Copyable
```

## Topics

### Initializers

- [init()](swift/mutablespan/init().md)

### Instance Properties

- [bytes](swift/mutablespan/bytes.md)
- [count](swift/mutablespan/count.md)
- [indices](swift/mutablespan/indices.md)
- [isEmpty](swift/mutablespan/isempty.md)
- [mutableBytes](swift/mutablespan/mutablebytes.md)
- [span](swift/mutablespan/span.md)

### Instance Methods

- [extracting(_:)](swift/mutablespan/extracting(_:)-2g8w3.md)
- [extracting(_:)](swift/mutablespan/extracting(_:)-80srp.md)
- [extracting(_:)](swift/mutablespan/extracting(_:)-bphj.md)
- [extracting(droppingFirst:)](swift/mutablespan/extracting(droppingfirst:).md)
- [extracting(droppingLast:)](swift/mutablespan/extracting(droppinglast:).md)
- [extracting(first:)](swift/mutablespan/extracting(first:).md)
- [extracting(last:)](swift/mutablespan/extracting(last:).md)
- [extracting(unchecked:)](swift/mutablespan/extracting(unchecked:)-23qq.md)
- [extracting(unchecked:)](swift/mutablespan/extracting(unchecked:)-4y8oj.md)
- [swapAt(_:_:)](swift/mutablespan/swapat(_:_:).md)
- [swapAt(unchecked:unchecked:)](swift/mutablespan/swapat(unchecked:unchecked:).md)
- [update(repeating:)](swift/mutablespan/update(repeating:).md)
- [withBytes(_:)](swift/mutablespan/withbytes(_:).md)
- [withUnsafeBufferPointer(_:)](swift/mutablespan/withunsafebufferpointer(_:).md)
- [withUnsafeBytes(_:)](swift/mutablespan/withunsafebytes(_:).md)
- [withUnsafeMutableBufferPointer(_:)](swift/mutablespan/withunsafemutablebufferpointer(_:).md)
- [withUnsafeMutableBytes(_:)](swift/mutablespan/withunsafemutablebytes(_:).md)

### Subscripts

- [subscript(_:)](swift/mutablespan/subscript(_:).md)
- [subscript(unchecked:)](swift/mutablespan/subscript(unchecked:).md)

### Type Aliases

- [MutableSpan.Index](swift/mutablespan/index.md)

### Default Implementations

- [BorrowingSequence Implementations](swift/mutablespan/borrowingsequence-implementations.md)

## Relationships

### Conforms To

- [BorrowingSequence](swift/borrowingsequence.md)
- [ContiguousBytes](foundation/contiguousbytes.md)
- [Sendable](swift/sendable.md)
- [SendableMetatype](swift/sendablemetatype.md)

## See Also

### Safe Memory Access

- [Span](swift/span.md)
- [RawSpan](swift/rawspan.md)
- [OutputSpan](swift/outputspan.md)
- [OutputRawSpan](swift/outputrawspan.md)
- [UTF8Span](swift/utf8span.md)
- [MutableRawSpan](swift/mutablerawspan.md)
