next up previous contents index
Next: The GFP Back Ends Up: User Guide to the Previous: Error Processing


Three forms of iteration are provided in a consistent fashion throughout the protocol: the mapcar- form, the mapc- form, and the do- form. The mapcar- applies a function to each element of a list and conses up the values returned by each invocation of the function. The mapc- form performs the same mapping operation, but does not cons the results. The do- form also iterates without consing, but its iteration binds a variable rather than mapping a function.

We wish to allow the kb argument to be an optional parameter that defaults to the current KB in virtually every operation in the protocol. Because CLOS does not allow the dispatching argument of a generic function to take on a default value, we define a macro wrapper around must GFP functions that assigns a default value to kb when needed, and then calls the actual generic function, whose name is the same as the macro suffixed with -internal.

All GFP functions, generic functions, macros, conditions and methods are defined in the Common Lisp package named "GFP". All of these definitions are exported.

AcknowledgementsFritz Mueller, James Rice, Suzanne Paley, and Karen Myers contributed to the concepts and implementation of GFP. This work has also benefited from comments by Richard Fikes and Robert MacGregor. This work was supported by ARPA contract F30602-92-C-0115.

  • Peter Karp