Commit 89835619 authored by Stefan Monnier's avatar Stefan Monnier
Browse files

(Finteractive_form): Use a `interactive-form' property if

present, analogous to the function-documentation property.
parent bffa7817
......@@ -204,6 +204,10 @@ remote connection has been established already.
** The two new functions `looking-at-p' and `string-match-p' can do
the same matching as `looking-at' and `string-match' without changing
the match data.
** The interactive-form of a function can be added post-facto via the
`interactive-form' symbol property. Mostly useful to add complex interactive
forms to subroutines.
* New Packages for Lisp Programming in Emacs 23.1
......
2007-07-25 Stefan Monnier <monnier@iro.umontreal.ca>
* data.c (Finteractive_form): Use a `interactive-form' property if
present, analogous to the function-documentation property.
2007-07-22 Nick Roberts <nickrob@snap.net.nz>
 
* xdisp.c (decode_mode_spec): Add case 'R' for to test for
......
......@@ -751,8 +751,14 @@ Value, if non-nil, is a list \(interactive SPEC). */)
Lisp_Object cmd;
{
Lisp_Object fun = indirect_function (cmd);
if (SUBRP (fun))
Lisp_Object tmp;
if (SYMBOLP (cmd)
/* Use an `interactive-form' property if present, analogous to the
function-documentation property. */
&& (tmp = Fget (cmd, intern ("interactive-form")), !NILP (tmp)))
return tmp;
else if (SUBRP (fun))
{
if (XSUBR (fun)->prompt)
return list2 (Qinteractive, build_string (XSUBR (fun)->prompt));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment