Hooks are treated in an ad hoc manner in many existing Lisp systems. This section gives a more systematic treatment of hooks, during which both syntactic and semantic issues are settled. In section 6, the platform established in this section will be used to build tools that support the process of learning about and attaching the hooks in Lisp programs.
The details of the hook mechanism must be adapted to the specific Lisp dialect in question. As a case study, we have implemented the whole framework in Emacs Lisp , which is a dynamically scoped and fairly traditional dialect of Lisp. As for this paper, we will keep the discussion at a general Lisp level rather than at the level of a particular Lisp dialect. Where appropriate, we mention the issues that depend on concrete dialects.