Documentation ¶
Overview ¶
Released under an MIT license. See LICENSE.
Package pair provides oh's cons cell type.
Index ¶
- Variables
- func Caar(c cell.I) cell.I
- func Caddr(c cell.I) cell.I
- func Cadr(c cell.I) cell.I
- func Car(c cell.I) cell.I
- func Cdar(c cell.I) cell.I
- func Cddr(c cell.I) cell.I
- func Cdr(c cell.I) cell.I
- func Cons(h, t cell.I) cell.I
- func Is(c cell.I) bool
- func SetCar(c, value cell.I)
- func SetCdr(c, value cell.I)
- type T
Constants ¶
This section is empty.
Variables ¶
var ( // Null is the empty list. It is also used to mark the end of a list. Null cell.I )
Functions ¶
func Caar ¶
Caar returns the car of the car of the pair c. A non-pair value where a pair is expected will cause a panic.
func Caddr ¶
Caddr returns the car of the cdr of the cdr of the pair c. A non-pair value where a pair is expected will cause a panic.
func Cadr ¶
Cadr returns the car of the cdr of the pair c. A non-pair value where a pair is expected will cause a panic.
func Car ¶
Car returns the car/head/first member of the pair c. If c is not a pair, this function will panic.
func Cdar ¶
Cdar returns the cdr of the car of the pair c. A non-pair value where a pair is expected will cause a panic.
func Cddr ¶
Cddr returns the cdr of the cdr of the pair c. A non-pair value where a pair is expected will cause a panic.
func Cdr ¶
Cdr returns the cdr/tail/rest member of the pair c. If c is not a pair, this function will panic.