[slime-devel] SLIME+sbcl: list-callees, list-callers on macros

Tobias C Rittweiler tcr at freebits.de
Fri Aug 27 19:39:53 UTC 2010

In article <87aaoajsux.fsf at desktop-ng.home.sw4me.com>,
 Anton Kovalenko <anton at sw4me.com> wrote:

> Hello SLIME developers,
> When slime-list-callees is attempted on symbol naming a macro,
> swank-sbcl implementation (based on SB-INTROSPECT) generates the
> following condition:
>  The value of sb-introspect::code is #<unknown pointer object,
>  widetag=#x5D {1003543DFF}>, which is not of type
>  sb-kernel:code-component.

This sounds like a bug in SBCL. Please submit that to its
bug tracker.

> Though (FDEFINITION)'s value for macros in SBCL _is_ FUNCTIONP,
> it's apparently a wrong kind of function for SB-INTROSPECT.
> After redefining LIST-CALLEES to use symbol's MACRO-FUNCTION in
> preference to FDEFINITION, I've got a desired behavior (listing callees
> of macrofunction seems to be a reasonable reaction, and that's what I
> want, anyway). Just in case someone finds it useful -- patch is
> attached.
> One more thing that I found convenient is redirecting LIST-CALLERS for
> symbols with macro-functions to WHO-MACROEXPANDS (also included in the
> patch).

List-Callers and Who-Foo are seperate functions bound to
different keys because they're based on totally different
lookup mechanism (at least that's my post-hoc reckoning.)
I don't think it's a good idea starting to intermix their


More information about the slime-devel mailing list