You may want to perform special actions when certain types of object are garbage collected, using the functions
add-special-free-action,
flag-special-free-action,
flag-not-special-free-action and
remove-special-free-action.
For example, when an open file stream is garbage collected, the file descriptor must be closed. This operation is performed as a special action.