View Source Document

tail.robin

;'<<SPEC'

### `tail` ###

    -> Tests for functionality "Evaluate core Robin Expression"

`tail` evaluates its argument to a list, and evaluates to the tail of that
list (the sublist obtained by removing the first element.)

    | (tail (prepend #t (prepend #f ())))
    = (#f)

`tail` expects its argument to be a list.

    | (tail #f)
    ? abort (expected-list #f)

`tail` expects exactly one argument.

    | (tail (prepend #t ()) (prepend #f ()))
    ? abort (illegal-arguments ((prepend #t ()) (prepend #f ())))

    | (tail)
    ? abort (illegal-arguments ())

`tail` is basically equivalent to Scheme's `cdr`.

'<<SPEC'

(require tail)