Skip to content

Commit 1ac89af

Browse files
committed
clarify comments
1 parent 4df6dc8 commit 1ac89af

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

src/ast/mod.rs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -820,18 +820,19 @@ pub enum Subscript {
820820
/// {2,3,4,5}
821821
/// ```
822822
///
823-
/// Stride notation is also supported
823+
/// The lower and/or upper bound can be omitted to slice from the start or
824+
/// end of the array respectively.
825+
///
826+
/// See <https://www.postgresql.org/docs/current/arrays.html#ARRAYS-ACCESSING>.
827+
///
828+
/// Also supports an optional "stride" as the last element (this is not
829+
/// supported by postgres), e.g.
824830
///
825831
/// ```plaintext
826832
/// => select (array[1,2,3,4,5,6])[1:6:2];
827833
/// -----------
828834
/// {1,3,5}
829835
/// ```
830-
///
831-
/// The lower and/or upper bound can be omitted to slice from the start or
832-
/// end of the array respectively.
833-
///
834-
/// See <https://www.postgresql.org/docs/current/arrays.html#ARRAYS-ACCESSING>.
835836
Slice {
836837
lower_bound: Option<Expr>,
837838
upper_bound: Option<Expr>,

0 commit comments

Comments
 (0)