From: <bar...@ve...> - 2006-10-25 13:22:56
|
>From: Brian Downing <bdowning at lavos.net> >Date: 2006/10/25 Wed AM 12:48:22 CDT >To: baronsamdi at verizon.net >Cc: sbcl-devel at lists.sourceforge.net >Subject: Re: [Sbcl-devel] Disassemble error on interpreter >On Tue, Oct 24, 2006 at 06:26:30PM -0500, baronsamdi at verizon.net wrote: >> I apologize if this message is redundant, my first email seems to have >> gotten lost. >> >> SBCL 0.9.17: >> >> When the interpreter is turned on, then DISASSEMBLE signals an error >> when given an interpreted function. It's supposed to compile the >> function, then disassemble it. See >> >> http://www.lispworks.com/documentation/HyperSpec/Body/f_disass.htm > >Thanks for the report, I missed this earlier. > >Since this is a change to the SBCL core the fix will likely be submitted >after 0.9.18 (probably tomorrow or so). Here's a patch you can load >in the interim: > >(in-package :sb-disassem) > >(defun valid-extended-function-designator-for-disassemble-p (thing) > (cond ((legal-fun-name-p thing) > (compiled-fun-or-lose (fdefinition thing) thing)) > #+sb-eval > ((sb-eval:interpreted-function-p thing) > (compile nil thing)) > ((functionp thing) > thing) > ((and (listp thing) > (eq (car thing) 'lambda)) > (compile nil thing)) > (t nil))) > >-bcd Yes, that patch did the trick. Thank you. May the Supreme Evaluator bind all your life's variables to :happiness. On a similar note, I've noticed that when you diassemble a profiled function, you don't get the function's code, you get the (much bigger) code for the closure that PROFILE wrapped the function in. While this may not be worth fixing, it might be worth documenting. -Trout |