sequences-docs: add a bunch of related-words

char-rename
Alexander Iljin 2017-02-17 01:47:16 +03:00 committed by John Benediktsson
parent a6223e1ae3
commit 4968a4f6a5
1 changed files with 8 additions and 6 deletions

View File

@ -678,7 +678,7 @@ HELP: replace-slice
{ $description "Replaces a range of elements beginning at index " { $snippet "from" } " and ending before index " { $snippet "to" } " with a new sequence." }
{ $errors "Throws an error if " { $snippet "new" } " contains elements whose types are not permissible in " { $snippet "seq" } "." } ;
{ push prefix suffix } related-words
{ push push-either push-if pop pop* prefix suffix suffix! } related-words
HELP: suffix
{ $values { "seq" sequence } { "elt" object } { "newseq" sequence } }
@ -758,8 +758,6 @@ HELP: last
{ $description "Outputs the last element of a sequence." }
{ $errors "Throws an error if the sequence is empty." } ;
{ pop pop* } related-words
HELP: pop*
{ $values { "seq" "a resizable mutable sequence" } }
{ $description "Removes the last element and shortens the sequence." }
@ -908,7 +906,7 @@ HELP: append-as
}
} ;
{ append append-as } related-words
{ append append-as append! 3append 3append-as push-all } related-words
HELP: prepend
{ $values { "seq1" sequence } { "seq2" sequence } { "newseq" sequence } }
@ -963,8 +961,6 @@ HELP: 3append-as
}
} ;
{ 3append 3append-as } related-words
HELP: surround
{ $values { "seq1" sequence } { "seq2" sequence } { "seq3" sequence } { "newseq" sequence } }
{ $description "Outputs a new sequence with " { $snippet "seq1" } " inserted between " { $snippet "seq2" } " and " { $snippet "seq3" } "." }
@ -1109,6 +1105,12 @@ HELP: tail*
}
{ $errors "Throws an error if the index is out of bounds." } ;
{ tail tail* tail-slice tail-slice* } related-words
{ head head* head-slice head-slice* } related-words
{ cut cut* cut-slice } related-words
{ unclip unclip-slice unclip-last unclip-last-slice } related-words
{ first last but-last but-last-slice rest rest-slice } related-words
HELP: shorter?
{ $values { "seq1" sequence } { "seq2" sequence } { "?" boolean } }
{ $description "Tests if the length of " { $snippet "seq1" } " is smaller than the length of " { $snippet "seq2" } "." } ;