Structural Informatics Group (SIG) logo
Home | Projects | Demos | Downloads | Publications | Local Info | About Us | New site
Go to the first, previous, next, last section, table of contents.

null

null

type: predicate function (subr)
location: built-in
source file: xlbfun.c
Common LISP compatible: yes
supported on: all machines

SYNTAX

(null <expr> )
        <expr>          -       the expression to check

DESCRIPTION

The NULL predicate checks <expr> for an empty list. T is returned if the list is empty, NIL is returned otherwise. The <expr> does not have to be a valid list, but if it is not a list then NIL is returned as the result.

EXAMPLES

(null '())                              ; returns T - empty list
(null ())                               ; returns T - still empty
(setq a NIL)                            ; set up a variable
(null a)                                ; returns T - value = empty list
                                        ;
(null "a")                              ; returns NIL - not a list
(null 'a)                               ; returns NIL - not a list

NOTE: The NULL predicate is the same function as the NOT predicate.


Go to the first, previous, next, last section, table of contents.