#include <sicstus/sicstus.h> int SP_get_list(SP_term_ref term, SP_term_ref head, SP_term_ref tail);
tail the head and tail of
a Prolog list.
The SP_term_ref holding the list
The SP_term_ref to be assigned the head
The SP_term_ref to be assigned the tail
Zero if the conversion fails (as far as failure can be detected), and a nonzero value otherwise.
Accessing Prolog Terms.