# editor: Implement \`From\` instead of \`Into\` for converting \`BlockId\`s to \`ElementId\`s \(\#14839\) · gitcafe/zed

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

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

Visibility: public

Requested revision: a5b8094082ec5c033e976572fb5cf48309e5d6b1

Requested commit: a5b8094082ec5c033e976572fb5cf48309e5d6b1

Commit: a5b8094082ec5c033e976572fb5cf48309e5d6b1

Tree: 6e85ddc2af2b642e9a1853feac28b1c747a9ed5b

Author: Marshall Bowers

Committer: GitHub

## Message

```
editor: Implement `From` instead of `Into` for converting `BlockId`s  to `ElementId`s (#14839)

This PR replaces the `Into<ElementId> for BlockId` implementation with
`From<BlockId> for ElementId`.

This keeps in line with Rust's guidance for preferring implementing
`From`, and gives us more flexibility when converting.

Release Notes:

- N/A
```

## Parents

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

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