Index: simple.el =================================================================== RCS file: /sources/emacs/emacs/lisp/simple.el,v retrieving revision 1.812 diff -c -r1.812 simple.el *** simple.el 20 Aug 2006 12:16:58 -0000 1.812 --- simple.el 5 Sep 2006 15:06:12 -0000 *************** *** 2809,2823 **** (defun zap-to-char (arg char) "Kill up to and including ARG'th occurrence of CHAR. ! Case is ignored if `case-fold-search' is non-nil in the current buffer. ! Goes backward if ARG is negative; error if CHAR not found." (interactive "p\ncZap to char: ") (if (char-table-p translation-table-for-input) (setq char (or (aref translation-table-for-input char) char))) ! (kill-region (point) (progn ! (search-forward (char-to-string char) nil nil arg) ! ; (goto-char (if (> arg 0) (1- (point)) (1+ (point)))) ! (point)))) ;; kill-line and its subroutines. --- 2809,2825 ---- (defun zap-to-char (arg char) "Kill up to and including ARG'th occurrence of CHAR. ! Case is ignored if `case-fold-search' is non-nil in the current buffer and ! CHAR is lowercase. Goes backward if ARG is negative; error if CHAR not found." (interactive "p\ncZap to char: ") (if (char-table-p translation-table-for-input) (setq char (or (aref translation-table-for-input char) char))) ! (let ((case-fold-search (and case-fold-search ! (not (eq char (upcase char)))))) ! (kill-region (point) (progn ! (search-forward (char-to-string char) nil nil arg) ! ; (goto-char (if (> arg 0) (1- (point)) (1+ (point)))) ! (point))))) ;; kill-line and its subroutines. Index: ChangeLog =================================================================== RCS file: /sources/emacs/emacs/lisp/ChangeLog,v retrieving revision 1.9966 diff -c -0 -r1.9966 ChangeLog *** ChangeLog 27 Aug 2006 07:08:19 -0000 1.9966 --- ChangeLog 5 Sep 2006 15:06:21 -0000 *************** *** 0 **** --- 1,5 ---- + 2006-09-05 Michaël Cadilhac + + * simple.el (zap-to-char): Be case sensitive if the character to zap to + is uppercase. +