Npt documentation.
Reference: ANSI Common Lisp npt
The following function specifications are described in lisp.h
.
int lisp_hold_p(addr x);
void lisp_hold_value(addr x, addr *ret);
void lisp_hold_set(addr x, addr value);
(addr x);
addr Lisp_holdvvoid lisp_hold(addr *ret, addr value);
(void); addr Lisp_hold
void lisp_nil(addr x);
void lisp_t(addr x);
(void);
addr Lisp_nil(void); addr Lisp_t
int lisp_nil_p(addr x);
int lisp_t_p(addr x);
int lisp_null_p(addr x);
int lisp_character_p(addr x);
int lisp_cons_p(addr x);
int lisp_list_p(addr x);
int lisp_string_p(addr x);
int lisp_symbol_p(addr x);
int lisp_strvect_p(addr x);
int lisp_array_p(addr x);
int lisp_vector_p(addr x);
int lisp_fixnum_p(addr x);
int lisp_bignum_p(addr x);
int lisp_integer_p(addr x);
int lisp_ratio_p(addr x);
int lisp_rational_p(addr x);
int lisp_single_float_p(addr x);
int lisp_double_float_p(addr x);
int lisp_long_float_p(addr x);
int lisp_float_p(addr x);
int lisp_real_p(addr x);
int lisp_complex_p(addr x);
int lisp_number_p(addr x);
int lisp_clos_p(addr x);
int lisp_hashtable_p(addr x);
int lisp_readtable_p(addr x);
int lisp_control_p(addr x);
int lisp_callname_p(addr x);
int lisp_function_p(addr x);
int lisp_package_p(addr x);
int lisp_random_state_p(addr x);
int lisp_pathname_p(addr x);
int lisp_stream_p(addr x);
int lisp_restart_p(addr x);
int lisp_environment_p(addr x);
int lisp_bitvector_p(addr x);
int lisp_print_dispatch_p(addr x);
Function of the hold variable.
int lisp_hold_p(addr x);
void lisp_hold_value(addr x, addr *ret);
void lisp_hold_set(addr x, addr value);
(addr x);
addr Lisp_holdvvoid lisp_hold(addr *ret, addr value);
(void); addr Lisp_hold
lisp_hold_p
int lisp_hold_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, non-zero is returned.
lisp_hold_value
void lisp_hold_value(addr x, addr *ret);
: x Object
Input: ret Object Output
If x
is a hold variable, the referenced object is returned to ret
.
If x
is not a hold variable, x
is returned to ret
as is.
lisp_hold_set
void lisp_hold_set(addr x, addr value);
: x Hold variable
Input: value Object Input
Stores the object in the x
hold variable.
If value
is a hold variable, the object held by value
is stored in x
.
Lisp_holdv
(addr x);
addr Lisp_holdv
: x Object
Input: Object Return
Same as the function lisp_hold_value
, but returns an object.
If x
is a hold variable, the stored object is returned.
If x
is not a hold variable, the input is returned as is.
lisp_hold
void lisp_hold(addr *ret, addr value);
: value Object
input: ret Hold variable Output
Create a hold variable and store the value
and return it to ret
.
If value
is a hold variable, the value held by the function is used.
Lisp_hold
(void);
addr Lisp_hold
: hold variable Return
Creates and returns a hold variable.
The value of the hold variable is NIL
.
Function of the boolean.
void lisp_nil(addr x);
void lisp_t(addr x);
(void);
addr Lisp_nil(void); addr Lisp_t
lisp_nil
void lisp_nil(addr x);
: x Hold variable Output
Store the nil
object in the x
hold variable.
lisp_t
void lisp_t(addr x);
: x Hold variable Output
Store the t
object in the x
hold variable.
Lisp_nil
(void);
addr Lisp_nil
: nil Return
Return a nil
object.
Lisp_t
(void);
addr Lisp_t
: t Return
Return a t
object.
Function of the system object.
int lisp_nil_p(addr x);
int lisp_t_p(addr x);
int lisp_null_p(addr x);
int lisp_character_p(addr x);
int lisp_cons_p(addr x);
int lisp_list_p(addr x);
int lisp_string_p(addr x);
int lisp_symbol_p(addr x);
int lisp_strvect_p(addr x);
int lisp_array_p(addr x);
int lisp_vector_p(addr x);
lisp_nil_p
int lisp_nil_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is nil
, a non-zero value is returned.
lisp_t_p
int lisp_t_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is t
, a non-zero value is returned.
lisp_null_p
int lisp_null_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is a NULL pointer, a non-zero pointer is returned.
The NULL pointer is the same as (void *)0
in C. It is not the same as NIL
in Common Lisp.
lisp_character_p
int lisp_character_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is a character type, a non-zero value is returned.
lisp_cons_p
int lisp_cons_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is a cons, a non-zero value is returned.
lisp_list_p
int lisp_list_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is a list, a non-zero value is returned. A list is a NIL
or cons.
lisp_string_p
int lisp_string_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is a string, a non-zero value is returned.
A string is an object of type LISPTYPE_STRING
or a specialized array of one dimensional characters of type LISPTYPE_ARRAY
.
lisp_strvect_p
int lisp_strvect_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is LISPTYPE_STRING
type, a non-zero value is returned.
This is different from stringp
in Common Lisp.
lisp_symbol_p
int lisp_symbol_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is a symbol, a non-zero value is returned.
lisp_array_p
int lisp_array_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is LISPTYPE_ARRAY
type, a non-zero value is returned.
This is different from arrayp
in Common Lisp.
lisp_vector_p
int lisp_vector_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is LISPTYPE_VECTOR
type, a non-zero value is returned.
This is different from vectorp
in Common Lisp.
Function of the number object.
int lisp_fixnum_p(addr x);
int lisp_bignum_p(addr x);
int lisp_integer_p(addr x);
int lisp_ratio_p(addr x);
int lisp_rational_p(addr x);
int lisp_single_float_p(addr x);
int lisp_double_float_p(addr x);
int lisp_long_float_p(addr x);
int lisp_float_p(addr x);
int lisp_real_p(addr x);
int lisp_complex_p(addr x);
int lisp_number_p(addr x);
lisp_fixnum_p
int lisp_fixnum_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is LISPTYPE_FIXNUM
type, a non-zero value is returned.
This is not exactly the same as (typep x 'fixnum)
in Common Lisp, but it is not different in normal use.
lisp_bignum_p
int lisp_bignum_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is LISPTYPE_BIGNUM
type, a non-zero value is returned.
lisp_integer_p
int lisp_integer_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is integer
type, a non-zero value is returned.
lisp_ratio_p
int lisp_ratio_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is ratio
type, a non-zero value is returned.
lisp_rational_p
int lisp_rational_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is rational
type, a non-zero value is returned.
lisp_single_float_p
int lisp_single_float_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is single-float
type, a non-zero value is returned.
lisp_double_float_p
int lisp_double_float_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is double-float
type, a non-zero value is returned.
lisp_long_float_p
int lisp_long_float_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is long-float
type, a non-zero value is returned.
lisp_float_p
int lisp_float_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is float
type, a non-zero value is returned.
lisp_real_p
int lisp_real_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is real
type, a non-zero value is returned.
lisp_complex_p
int lisp_complex_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is complex
type, a non-zero value is returned.
lisp_number_p
int lisp_number_p(addr x);
: x Object
Input: boolean Return
If x
is a hold variable, the value held by the variable is evaluated.
If x
is number
type, a non-zero value is returned.