# language: Remove some unnecessary cloning \(\#30229\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/a61958e886514396648fbbf1a8b34499c6f63d81)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: a61958e886514396648fbbf1a8b34499c6f63d81

Requested commit: a61958e886514396648fbbf1a8b34499c6f63d81

Commit: a61958e886514396648fbbf1a8b34499c6f63d81

Tree: 85dca63780378993eef9e3991e61437d123b888e

Author: tidely

Committer: GitHub

## Message

```
language: Remove some unnecessary cloning (#30229)

Another tiny patch to reduce allocations

`.iter().cloned().collect()` calls `Clone` per element, whereas
`into_iter().collect()` preallocates memory

Release Notes:

- N/A
```

## Parents

- [d06d0e6a94b1704cbf9113474041de0d810beab4](https://git.cafe/gitcafe/zed/commit/d06d0e6a94b1704cbf9113474041de0d810beab4?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/a61958e886514396648fbbf1a8b34499c6f63d81?format=markdown)
