unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* ELisp function prototypes and local function name
@ 2011-04-06 13:36 Ted Zlatanov
  2011-04-06 15:19 ` Robert Pluim
  0 siblings, 1 reply; 11+ messages in thread
From: Ted Zlatanov @ 2011-04-06 13:36 UTC (permalink / raw)
  To: emacs-devel

I often find myself needing to know the prototype of a function I'm
calling dynamically.  Is there a way to get that?  The ELisp reference
manual doesn't have the info AFAICT.

Also I'd like to have a simple way (tracing backwards through frames is
not it, because every form and its cousin get in there) to get the
symbol of the currently running function.  So I could say:

(defun blah ()
  (format "running in function %s" __FUNCTION_NAME__))

=> "running in function blah"

(defun info (function-name)
  (format "called from function %s" function-name))

(defun blah ()
   (info __FUNCTION_NAME__))

=> "called from function blah"

Is that possible?

Thanks
Ted




^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2011-04-08  5:43 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-06 13:36 ELisp function prototypes and local function name Ted Zlatanov
2011-04-06 15:19 ` Robert Pluim
2011-04-06 15:58   ` Ted Zlatanov
2011-04-07  0:25     ` Stephen J. Turnbull
2011-04-07  2:27       ` Ted Zlatanov
2011-04-07  3:27         ` Stephen J. Turnbull
2011-04-07  3:55           ` Jambunathan K
2011-04-07  5:43             ` Stephen J. Turnbull
2011-04-07 20:51           ` Ted Zlatanov
2011-04-08  4:01             ` Stephen J. Turnbull
2011-04-08  5:43               ` Ted Zlatanov

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).