[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/emacs-23 r100218: Make the yank-handler arg
From: |
Stefan Monnier |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/emacs-23 r100218: Make the yank-handler argument obsolete. |
Date: |
Wed, 17 Nov 2010 21:09:41 -0500 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 100218
committer: Stefan Monnier <address@hidden>
branch nick: emacs-23
timestamp: Wed 2010-11-17 21:09:41 -0500
message:
Make the yank-handler argument obsolete.
* simple.el (kill-new, kill-append, kill-region):
* comint.el (comint-kill-region): Make the yank-handler argument obsolete.
modified:
etc/NEWS
lisp/ChangeLog
lisp/comint.el
lisp/simple.el
=== modified file 'etc/NEWS'
--- a/etc/NEWS 2010-11-13 21:59:28 +0000
+++ b/etc/NEWS 2010-11-18 02:09:41 +0000
@@ -100,6 +100,7 @@
The old names are obsolete.
** The use of unintern without an obarray arg is declared obsolete.
** The function `princ-list' is declared obsolete.
+** The yank-handler argument to kill-region and friends is declared obsolete.
** New function byte-to-string, like char-to-string but for bytes.
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2010-11-17 19:59:16 +0000
+++ b/lisp/ChangeLog 2010-11-18 02:09:41 +0000
@@ -1,3 +1,8 @@
+2010-11-18 Stefan Monnier <address@hidden>
+
+ * simple.el (kill-new, kill-append, kill-region):
+ * comint.el (comint-kill-region): Make the yank-handler argument
obsolete.
+
2010-11-17 Stefan Monnier <address@hidden>
* emacs-lisp/smie.el (smie-bnf-classify): Signal errors for tokens
=== modified file 'lisp/comint.el'
--- a/lisp/comint.el 2010-10-23 19:15:44 +0000
+++ b/lisp/comint.el 2010-11-18 02:09:41 +0000
@@ -2641,6 +2641,7 @@
(let ((inhibit-read-only t))
(kill-region beg end yank-handler)
(comint-update-fence))))))
+(set-advertised-calling-convention 'comint-kill-new '(beg end) "23.3")
;; Support for source-file processing commands.
=== modified file 'lisp/simple.el'
--- a/lisp/simple.el 2010-10-12 23:25:19 +0000
+++ b/lisp/simple.el 2010-11-18 02:09:41 +0000
@@ -2831,11 +2831,6 @@
Optional second argument REPLACE non-nil means that STRING will replace
the front of the kill ring, rather than being added to the list.
-Optional third arguments YANK-HANDLER controls how the STRING is later
-inserted into a buffer; see `insert-for-yank' for details.
-When a yank handler is specified, STRING must be non-empty (the yank
-handler, if non-nil, is stored as a `yank-handler' text property on STRING).
-
When `save-interprogram-paste-before-kill' and `interprogram-paste-function'
are non-nil, saves the interprogram paste string(s) into `kill-ring' before
STRING.
@@ -2872,22 +2867,19 @@
(setq kill-ring-yank-pointer kill-ring)
(if interprogram-cut-function
(funcall interprogram-cut-function string (not replace))))
+(set-advertised-calling-convention
+ 'kill-new '(string &optional replace) "23.3")
(defun kill-append (string before-p &optional yank-handler)
"Append STRING to the end of the latest kill in the kill ring.
If BEFORE-P is non-nil, prepend STRING to the kill.
-Optional third argument YANK-HANDLER, if non-nil, specifies the
-yank-handler text property to be set on the combined kill ring
-string. If the specified yank-handler arg differs from the
-yank-handler property of the latest kill string, this function
-adds the combined string to the kill ring as a new element,
-instead of replacing the last kill with it.
If `interprogram-cut-function' is set, pass the resulting kill to it."
(let* ((cur (car kill-ring)))
(kill-new (if before-p (concat string cur) (concat cur string))
(or (= (length cur) 0)
(equal yank-handler (get-text-property 0 'yank-handler cur)))
yank-handler)))
+(set-advertised-calling-convention 'kill-append '(string before-p) "23.3")
(defcustom yank-pop-change-selection nil
"If non-nil, rotating the kill ring changes the window system selection."
@@ -2968,11 +2960,7 @@
Any command that calls this function is a \"kill command\".
If the previous command was also a kill command,
the text killed this time appends to the text killed last time
-to make one entry in the kill ring.
-
-In Lisp code, optional third arg YANK-HANDLER, if non-nil,
-specifies the yank-handler text property to be set on the killed
-text. See `insert-for-yank'."
+to make one entry in the kill ring."
;; Pass point first, then mark, because the order matters
;; when calling kill-append.
(interactive (list (point) (mark)))
@@ -3004,6 +2992,7 @@
(barf-if-buffer-read-only)
;; If the buffer isn't read-only, the text is.
(signal 'text-read-only (list (current-buffer)))))))
+(set-advertised-calling-convention 'kill-region '(beg end) "23.3")
;; copy-region-as-kill no longer sets this-command, because it's confusing
;; to get two copies of the text when the user accidentally types M-w and
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/emacs-23 r100218: Make the yank-handler argument obsolete.,
Stefan Monnier <=