analog of fundef for Maxima functions defined in lisp file



>>>>> "Edwin" == Edwin Woollett <woollett at charter.net> writes:

    Edwin> Is there an analog of fundef which can be used to
    Edwin> display the definition of Maxima functions which
    Edwin> have been loaded in via a lisp file?
    Edwin> ---------------------------------------
    Edwin> (%i1) functions;
    Edwin> (%o1)                                 []
    Edwin> (%i2) load ("rename.lisp");
    Edwin> (%o2)                             rename.lisp
    Edwin> (%i3) functions;
    Edwin> (%o3)                                 []
    Edwin> (%i4) fundef (rename1);
    Edwin> fundef: no such function: rename1
    Edwin> -- an error. To debug this try: debugmode(true);

I'm not aware of any such thing in maxima.  But you could try

:lisp (function-lambda-expression #'$rename1)

This isn't guaranteed to return anything, but for many Lisps it will
return the function.  For example, cmucl will return 

(LAMBDA (MFROM MTO)
  (BLOCK $RENAME1
    (CONS '(MLIST SIMP) (MULTIPLE-VALUE-LIST (RENAME-FILE MFROM MTO)))))


This definition might work for you:

(defun $lispfundef (f)
  (print (function-lambda-expression (coerce f 'function)))
  t)


Ray