forked from rebol/rebol
-
Notifications
You must be signed in to change notification settings - Fork 2
Repend
angerangel edited this page Mar 19, 2013
·
1 revision
REPEND series value /part length /only /dup count
Appends a reduced value to a series and returns the series head.
REPEND is a function value.
- series -- Series at point to insert (series! port! map! gob! object! bitset!)
- value -- The value to insert
-
/part -- Limits to a given length or position
- length (number! series! pair!)
- /only -- Inserts a series as a series
-
/dup -- Duplicates the insert a specified number of times
- count (number! pair!)
#SOURCE
repend: make function! [ [
{Appends a reduced value to a series and returns the series head.}
series [series! port! map! gob! object! bitset!] "Series at point to insert"
value "The value to insert"
/part "Limits to a given length or position"
length [number! series! pair!]
/only "Inserts a series as a series"
/dup "Duplicates the insert a specified number of times"
count [number! pair!]
][
apply :append [series reduce :value part length only dup count]
] ]