summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMattes Bieniarz <79235640+flauschpantoffel@users.noreply.github.com>2024-07-02 16:44:57 +0200
committerGitHub <noreply@github.com>2024-07-02 14:44:57 +0000
commit728fb7e475d024e7534aec1e47ea9b888671c1b3 (patch)
treedf21e111b55ebf10e858c290527093fb8d386fed
parentaefc506424345d3e671df0aafe31330f8becdf6d (diff)
fix(array.slice): Clarify and correct function description (#4446)
-rw-r--r--crates/typst/src/foundations/array.rs2
-rw-r--r--crates/typst/src/foundations/bytes.rs2
2 files changed, 2 insertions, 2 deletions
diff --git a/crates/typst/src/foundations/array.rs b/crates/typst/src/foundations/array.rs
index 2caefc13..bd7e7bca 100644
--- a/crates/typst/src/foundations/array.rs
+++ b/crates/typst/src/foundations/array.rs
@@ -259,7 +259,7 @@ impl Array {
.ok_or_else(|| out_of_bounds_no_default(index, self.len()))
}
- /// Extracts a subslice of the array. Fails with an error if the start or
+ /// Extracts a subslice of the array. Fails with an error if the start or end
/// index is out of bounds.
#[func]
pub fn slice(
diff --git a/crates/typst/src/foundations/bytes.rs b/crates/typst/src/foundations/bytes.rs
index 1e795859..5b77aa2a 100644
--- a/crates/typst/src/foundations/bytes.rs
+++ b/crates/typst/src/foundations/bytes.rs
@@ -127,7 +127,7 @@ impl Bytes {
.ok_or_else(|| out_of_bounds_no_default(index, self.len()))
}
- /// Extracts a subslice of the bytes. Fails with an error if the start or
+ /// Extracts a subslice of the bytes. Fails with an error if the start or end
/// index is out of bounds.
#[func]
pub fn slice(