Re: tracing a function without knowing its name
- From: Juho Snellman <jsnell@xxxxxx>
- Date: 29 Apr 2007 02:05:49 GMT
jimka <jimka@xxxxxxxxx> wrote:
Does anyone know how (or at least how with sbcl) to trace a function
object without knowing its name?
CL-USER> (defparameter *a* (lambda () 1))
*A*
CL-USER> (trace #.*a* :encapsulate nil)
(#<FUNCTION (LAMBDA #) {1003AC0109}>)
CL-USER> (funcall *a*)
0: ((LAMBDA ()))
0: #<FUNCTION (LAMBDA #) {1003AC0109}> returned 1
1
(Though beware that TRACE with :ENCAPSULATE NIL doesn't work on all
platforms that sbcl supports).
--
Juho Snellman
.
- References:
- tracing a function without knowing its name
- From: jimka
- tracing a function without knowing its name
- Prev by Date: Re: Any macro for inserting math "normally"
- Next by Date: Re: pattern-matching in LISP?
- Previous by thread: Re: tracing a function without knowing its name
- Next by thread: CL Scaling for High Traffic Web Sites
- Index(es):
Relevant Pages
|