---
title: AsyncStream.Iterator
framework: swift
role: symbol
role_heading: Structure
path: swift/asyncstream/iterator
---

# AsyncStream.Iterator

The asynchronous iterator for iterating an asynchronous stream.

## Declaration

```swift
struct Iterator
```

## Overview

Overview This type doesn’t conform to Sendable. Don’t use it from multiple concurrent contexts. It is a programmer error to invoke next() from a concurrent context that contends with another such call, which results in a call to fatalError().

## Topics

### Iterating over Elements

- [next()](swift/asyncstream/iterator/next().md)

### Instance Methods

- [next(isolation:)](swift/asyncstream/iterator/next(isolation:).md)

### Default Implementations

- [AsyncIteratorProtocol Implementations](swift/asyncstream/iterator/asynciteratorprotocol-implementations.md)

## Relationships

### Conforms To

- [AsyncIteratorProtocol](swift/asynciteratorprotocol.md)

## See Also

### Creating an Iterator

- [makeAsyncIterator()](swift/asyncstream/makeasynciterator().md)
