From 728fb7e475d024e7534aec1e47ea9b888671c1b3 Mon Sep 17 00:00:00 2001 From: Mattes Bieniarz <79235640+flauschpantoffel@users.noreply.github.com> Date: Tue, 2 Jul 2024 16:44:57 +0200 Subject: [PATCH] fix(array.slice): Clarify and correct function description (#4446) --- crates/typst/src/foundations/array.rs | 2 +- crates/typst/src/foundations/bytes.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/typst/src/foundations/array.rs b/crates/typst/src/foundations/array.rs index 2caefc133..bd7e7bca4 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 1e7958595..5b77aa2a6 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(