[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Is this tempo.el patch correct?
From: |
Richard Stallman |
Subject: |
Is this tempo.el patch correct? |
Date: |
Fri, 02 Mar 2007 18:47:16 -0500 |
Please tell us whether to install this patch.
------- Start of forwarded message -------
To: address@hidden
From: Lawrence Mitchell <address@hidden>
Date: Fri, 02 Mar 2007 14:39:11 +0000
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Subject: r> insertion marker not handled correctly in tempo
X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=failed
version=3.0.4
If you define a tempo template that includes the "r>" insertion
marker, attempting to use that template results in an error that the
function "r>" is undefined.
This bug may be reproduced as follows:
emacs -Q
Evaluate:
(progn
(require 'tempo)
(tempo-define-template
"show-bug"
'("Some string" n> (r> "body: ")))
(setq debug-on-error t)
(tempo-template-show-bug))
The following patch fixes this problem in, I believe, the correct
manner:
Index: tempo.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/tempo.el,v
retrieving revision 1.20.6.11
diff -c -r1.20.6.11 tempo.el
*** tempo.el 26 Jan 2007 06:15:15 -0000 1.20.6.11
- --- tempo.el 2 Mar 2007 14:36:39 -0000
***************
*** 352,357 ****
- --- 352,364 ----
(goto-char tempo-region-stop)
(tempo-insert-prompt-compat
(cdr element))))
+ ((and (consp element)
+ (eq (car element) 'r>)) (if on-region
+ (progn
+ (goto-char tempo-region-stop)
+ (indent-region (mark) (point)
nil))
+ (tempo-insert-prompt-compat
+ (cdr element))))
((and (consp element)
(eq (car element) 's)) (tempo-insert-named (car (cdr element))))
((and (consp element)
Changelog entry:
2007-03-02 Lawrence Mitchell <address@hidden>
* tempo.el (tempo-insert): Deal with 'r> if it appears
specified with a prompt argument.
Cheers,
Lawrence
- --
Lawrence Mitchell <address@hidden>
_______________________________________________
emacs-pretest-bug mailing list
address@hidden
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug
------- End of forwarded message -------
- Is this tempo.el patch correct?,
Richard Stallman <=