fix(span): correct doc comments (#3608)

Fix doc comments for `Span` methods. `Span` offsets are in bytes, not
characters.
This commit is contained in:
overlookmotel 2024-06-10 16:24:29 +01:00 committed by GitHub
parent c95d691af6
commit d65202d788
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -74,7 +74,7 @@ impl Span {
Self { start: at, end: at }
}
/// Create a new [`Span`] starting at `start` and covering `size` characters.
/// Create a new [`Span`] starting at `start` and covering `size` bytes.
///
/// # Example
/// ```
@ -88,7 +88,7 @@ impl Span {
Self::new(start, start + size)
}
/// Get the number of characters covered by the [`Span`].
/// Get the number of bytes covered by the [`Span`].
///
/// # Example
/// ```