list

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 31, 2023 License: EUPL-1.2 Imports: 2 Imported by: 1

Documentation

Overview

Package list contains all list-related builtins

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Append

func Append(args []sxpf.Object) (sxpf.Object, error)

Append returns a list where all list arguments are concatenated.

func Car

func Car(args []sxpf.Object) (sxpf.Object, error)

Car returns the car of a pair argument.

func Cdr

func Cdr(args []sxpf.Object) (sxpf.Object, error)

Cdr returns the cdr of a pair argument.

func Cons

func Cons(args []sxpf.Object) (sxpf.Object, error)

Cons returns a cons pair of the two arguments.

func Last

func Last(args []sxpf.Object) (sxpf.Object, error)

Last returns the last element of a list

func Length

func Length(args []sxpf.Object) (sxpf.Object, error)

Length returns the length of the given list.

func List

func List(args []sxpf.Object) (sxpf.Object, error)

List returns a list of all arguments.

func ListP

func ListP(args []sxpf.Object) (sxpf.Object, error)

ListP returns True if the argument is a (proper) list.

func ListStar

func ListStar(args []sxpf.Object) (sxpf.Object, error)

ListStar returns a list of all arguments, when the last argument is a cons to the second last.

func NullP

func NullP(args []sxpf.Object) (sxpf.Object, error)

NullP returns True if the argument is nil.

func PairP

func PairP(args []sxpf.Object) (sxpf.Object, error)

PairP returns True if the argument is a cons cell.

func Reverse

func Reverse(args []sxpf.Object) (sxpf.Object, error)

Reverse returns a reversed list.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL