Skip to content

Conversation

Veykril
Copy link
Member

@Veykril Veykril commented May 18, 2024

No description provided.

Ok(TextRange::new(
value.start.try_into()?,
value.end.try_into()?,
))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should check that start <= end?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That would require me to rethink the error type and I didn't want to bother with that 😬 I guess discarding the TryInto<TextSize> error and replacing it with a generic one here would be probably fine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants