# HG changeset patch # User Stefan Monnier # Date 1189391382 0 # Node ID 74dfb3b7d8f271cc9eff53734f3b70edadd354cd # Parent de15045ac6fe3fab9eb405093eb05a87facfd80c (Fcall_interactively): Use Finteractive_form also for subrs and compiled functions. diff -r de15045ac6fe -r 74dfb3b7d8f2 src/ChangeLog --- a/src/ChangeLog Mon Sep 10 01:20:44 2007 +0000 +++ b/src/ChangeLog Mon Sep 10 02:29:42 2007 +0000 @@ -1,3 +1,8 @@ +2007-09-10 Stefan Monnier + + * callint.c (Fcall_interactively): Use Finteractive_form also for subrs + and compiled functions. + 2007-09-08 Fredrik Axelsson * window.c (prefer_window_split_horizontally): New variable. diff -r de15045ac6fe -r 74dfb3b7d8f2 src/callint.c --- a/src/callint.c Mon Sep 10 01:20:44 2007 +0000 +++ b/src/callint.c Mon Sep 10 02:29:42 2007 +0000 @@ -332,32 +332,16 @@ /* Decode the kind of function. Either handle it and return, or go to `lose' if not interactive, or set either STRING or SPECS. */ - if (SUBRP (fun)) - { - string = (unsigned char *) XSUBR (fun)->prompt; - if (!string) - { - lose: - wrong_type_argument (Qcommandp, function); - } - } - else if (COMPILEDP (fun)) - { - if ((XVECTOR (fun)->size & PSEUDOVECTOR_SIZE_MASK) <= COMPILED_INTERACTIVE) - goto lose; - specs = XVECTOR (fun)->contents[COMPILED_INTERACTIVE]; - } - else - { - Lisp_Object form; - GCPRO2 (function, prefix_arg); - form = Finteractive_form (function); - UNGCPRO; - if (CONSP (form)) - specs = filter_specs = Fcar (XCDR (form)); - else - goto lose; - } + { + Lisp_Object form; + GCPRO2 (function, prefix_arg); + form = Finteractive_form (function); + UNGCPRO; + if (CONSP (form)) + specs = filter_specs = Fcar (XCDR (form)); + else + wrong_type_argument (Qcommandp, function); + } /* If either SPECS or STRING is set to a string, use it. */ if (STRINGP (specs)) @@ -368,7 +352,7 @@ bcopy (SDATA (specs), string, SBYTES (specs) + 1); } - else if (string == 0) + else { Lisp_Object input; i = num_input_events;