The following functions are provided for testing Prolog terms. They return BP_TRUE when they succeed, and they return BP_FALSE when they fail.
- int bp_is_atom(TERM t):
Term t is an atom.
- int bp_is_integer(TERM t):
Term t is an integer.
- int bp_is_float(TERM t):
Term t is a floating-point number.
- int bp_is_nil(TERM t):
Term t is a nil.
- int bp_is_list(TERM t):
Term t is a list.
- int bp_is_structure(TERM t):
Term t is a structure (but not a list).
- int bp_is_compound(TERM t):
This predicate is true if bp_is_list(t) is true, or if bp_is_structure(t) is true.
- int bp_is_unifiable(TERM t1, TERM t2):
Terms t1 and t2 are unifiable. This is equivalent to the Prolog call not(not(t1=t2)).
- int bp_is_identical(TERM t1, TERM t2):
Terms t1 and t2 are identical. This function is equivalent to the Prolog call t1==t2.
Neng-Fa Zhou
2013-01-25