Next: Testing Prolog terms
Up: Calling C from Prolog
Previous: Term representation
  Contents
  Index
Every C function that defines a Prolog predicate should not take any argument. The macro ARG(i,arity) is used to get the arguments passed from a Prolog call:
- TERM ARG(int i, int arity) Fetch the ith argument, where arity is the arity of the predicate, and i must be an integer between 1 and arity.
Neng-Fa Zhou
1999-11-24