emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ELisp function prototypes and local function name


From: Ted Zlatanov
Subject: Re: ELisp function prototypes and local function name
Date: Wed, 06 Apr 2011 10:58:00 -0500
User-agent: Gnus/5.110016 (No Gnus v0.16) Emacs/24.0.50 (gnu/linux)

On Wed, 06 Apr 2011 17:19:49 +0200 Robert Pluim <address@hidden> wrote: 

RP> Ted Zlatanov <address@hidden> writes:
>> 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.

RP> You mean like eldoc-mode?

Oh yes, I didn't think to check there.  It looks like that calls the
following (example with `mapc'):

(help-split-fundoc (documentation 'mapc t) 'mapc)

That seems nasty, taking text documentation and splitting it back to get
the function arguments.  Is that really the only way to get back the
prototype?  It seems like `eldoc-get-fnsym-args-string' should be able
to do something simpler.

The interpreter knows how many arguments a function expects and signals
an error if the count is incorrect.  Can that be used instead of the
above?

Ted




reply via email to

[Prev in Thread] Current Thread [Next in Thread]