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


Equality predicates

These C functions mirror Scheme's equality predicate procedures with one important difference. The C routines return C boolean values (0 and 1) instead of SCM_BOOL_T and SCM_BOOL_F.

The Scheme notational convention of putting a ? at the end of predicate procedure names is mirrored in C by placing _p at the end of the procedure. For example, (equal? ...) maps to gh_equal_p(...).

Function: int gh_eq_p (SCM x, SCM y)
Returns 1 if x and y are equal in the sense of Scheme's eq? predicate, 0 otherwise.

Function: int gh_eqv_p (SCM x, SCM y)
Returns 1 if x and y are equal in the sense of Scheme's eqv? predicate, 0 otherwise.

Function: int gh_equal_p (SCM x, SCM y)
Returns 1 if x and y are equal in the sense of Scheme's equal? predicate, 0 otherwise.

Function: int gh_string_equal_p (SCM s1, SCM s2)
Returns 1 if the strings s1 and s2 are equal, 0 otherwise.

Function: int gh_null_p (SCM l)
Returns 1 if l is an empty list or pair; 0 otherwise.


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