If you implement an Objective-C class in Lisp but its name is not referenced at runtime, then you need to arrange for this symbol to be retained during delivery.
This can be achieved with :keep-symbols, but a more modular approach is to keep the name on the plist of some other symbol. For example the internal CAPI class
lw-slider is defined like this:
(objc:define-objc-class lw-slider ()
lw-slider is retained like this:
(setf (get 'slider-representation 'owner-class)
In this case, the code for
slider-representation is the only thing that makes the LWSlider object, so it is the best place to retain it (that is, only if
slider-representation is retained).
LispWorks Delivery User Guide - 15 Feb 2015