diff options
| author | Stefan Monnier | 2010-09-14 13:11:44 +0200 |
|---|---|---|
| committer | Stefan Monnier | 2010-09-14 13:11:44 +0200 |
| commit | f3a30a50fab486dcaafb9d897797794fe4c3c4b3 (patch) | |
| tree | 6026256a197c5a9f50fa0c5627122d0894d76b5a | |
| parent | 67ae97667d185e23a24a98f295bcf1cd9c788cb5 (diff) | |
| download | emacs-f3a30a50fab486dcaafb9d897797794fe4c3c4b3.tar.gz emacs-f3a30a50fab486dcaafb9d897797794fe4c3c4b3.zip | |
* subr.el (unintern): Declare the obarray arg mandatory.
* emacs-lisp/byte-run.el (set-advertised-calling-convention):
Add `when' argument. Update callers.
| -rw-r--r-- | etc/NEWS | 2 | ||||
| -rw-r--r-- | lisp/ChangeLog | 7 | ||||
| -rw-r--r-- | lisp/emacs-lisp/byte-run.el | 13 | ||||
| -rw-r--r-- | lisp/subr.el | 13 |
4 files changed, 23 insertions, 12 deletions
| @@ -40,6 +40,8 @@ This can be used in place of the default appt-message-warning-time. | |||
| 40 | 40 | ||
| 41 | * Lisp changes in Emacs 23.3 | 41 | * Lisp changes in Emacs 23.3 |
| 42 | 42 | ||
| 43 | ** The use of unintern without an obarray arg is declared obsolete. | ||
| 44 | |||
| 43 | ** New function byte-to-string, like char-to-string but for bytes. | 45 | ** New function byte-to-string, like char-to-string but for bytes. |
| 44 | 46 | ||
| 45 | 47 | ||
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6098dad51de..f60d1a80f27 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,10 @@ | |||
| 1 | 2010-09-14 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * emacs-lisp/byte-run.el (set-advertised-calling-convention): | ||
| 4 | Add `when' argument. Update callers. | ||
| 5 | |||
| 6 | * subr.el (unintern): Declare the obarray arg mandatory. | ||
| 7 | |||
| 1 | 2010-09-14 Glenn Morris <rgm@gnu.org> | 8 | 2010-09-14 Glenn Morris <rgm@gnu.org> |
| 2 | 9 | ||
| 3 | * calendar/diary-lib.el (diary-list-entries-hook, diary-sort-entries): | 10 | * calendar/diary-lib.el (diary-list-entries-hook, diary-sort-entries): |
diff --git a/lisp/emacs-lisp/byte-run.el b/lisp/emacs-lisp/byte-run.el index dbbf057ae22..e6810fc8b72 100644 --- a/lisp/emacs-lisp/byte-run.el +++ b/lisp/emacs-lisp/byte-run.el | |||
| @@ -108,10 +108,11 @@ The return value of this function is not used." | |||
| 108 | 108 | ||
| 109 | (defvar advertised-signature-table (make-hash-table :test 'eq :weakness 'key)) | 109 | (defvar advertised-signature-table (make-hash-table :test 'eq :weakness 'key)) |
| 110 | 110 | ||
| 111 | (defun set-advertised-calling-convention (function signature) | 111 | (defun set-advertised-calling-convention (function signature when) |
| 112 | "Set the advertised SIGNATURE of FUNCTION. | 112 | "Set the advertised SIGNATURE of FUNCTION. |
| 113 | This will allow the byte-compiler to warn the programmer when she uses | 113 | This will allow the byte-compiler to warn the programmer when she uses |
| 114 | an obsolete calling convention." | 114 | an obsolete calling convention. WHEN specifies since when the calling |
| 115 | convention was modified." | ||
| 115 | (puthash (indirect-function function) signature | 116 | (puthash (indirect-function function) signature |
| 116 | advertised-signature-table)) | 117 | advertised-signature-table)) |
| 117 | 118 | ||
| @@ -132,7 +133,7 @@ was first made obsolete, for example a date or a release number." | |||
| 132 | obsolete-name) | 133 | obsolete-name) |
| 133 | (set-advertised-calling-convention | 134 | (set-advertised-calling-convention |
| 134 | ;; New code should always provide the `when' argument. | 135 | ;; New code should always provide the `when' argument. |
| 135 | 'make-obsolete '(obsolete-name current-name when)) | 136 | 'make-obsolete '(obsolete-name current-name when) "23.1") |
| 136 | 137 | ||
| 137 | (defmacro define-obsolete-function-alias (obsolete-name current-name | 138 | (defmacro define-obsolete-function-alias (obsolete-name current-name |
| 138 | &optional when docstring) | 139 | &optional when docstring) |
| @@ -153,7 +154,7 @@ See the docstrings of `defalias' and `make-obsolete' for more details." | |||
| 153 | (set-advertised-calling-convention | 154 | (set-advertised-calling-convention |
| 154 | ;; New code should always provide the `when' argument. | 155 | ;; New code should always provide the `when' argument. |
| 155 | 'define-obsolete-function-alias | 156 | 'define-obsolete-function-alias |
| 156 | '(obsolete-name current-name when &optional docstring)) | 157 | '(obsolete-name current-name when &optional docstring) "23.1") |
| 157 | 158 | ||
| 158 | (defun make-obsolete-variable (obsolete-name current-name &optional when) | 159 | (defun make-obsolete-variable (obsolete-name current-name &optional when) |
| 159 | "Make the byte-compiler warn that OBSOLETE-NAME is obsolete. | 160 | "Make the byte-compiler warn that OBSOLETE-NAME is obsolete. |
| @@ -175,7 +176,7 @@ was first made obsolete, for example a date or a release number." | |||
| 175 | obsolete-name) | 176 | obsolete-name) |
| 176 | (set-advertised-calling-convention | 177 | (set-advertised-calling-convention |
| 177 | ;; New code should always provide the `when' argument. | 178 | ;; New code should always provide the `when' argument. |
| 178 | 'make-obsolete-variable '(obsolete-name current-name when)) | 179 | 'make-obsolete-variable '(obsolete-name current-name when) "23.1") |
| 179 | 180 | ||
| 180 | (defmacro define-obsolete-variable-alias (obsolete-name current-name | 181 | (defmacro define-obsolete-variable-alias (obsolete-name current-name |
| 181 | &optional when docstring) | 182 | &optional when docstring) |
| @@ -210,7 +211,7 @@ CURRENT-NAME, if it does not already have them: | |||
| 210 | (set-advertised-calling-convention | 211 | (set-advertised-calling-convention |
| 211 | ;; New code should always provide the `when' argument. | 212 | ;; New code should always provide the `when' argument. |
| 212 | 'define-obsolete-variable-alias | 213 | 'define-obsolete-variable-alias |
| 213 | '(obsolete-name current-name when &optional docstring)) | 214 | '(obsolete-name current-name when &optional docstring) "23.1") |
| 214 | 215 | ||
| 215 | ;; FIXME This is only defined in this file because the variable- and | 216 | ;; FIXME This is only defined in this file because the variable- and |
| 216 | ;; function- versions are too. Unlike those two, this one is not used | 217 | ;; function- versions are too. Unlike those two, this one is not used |
diff --git a/lisp/subr.el b/lisp/subr.el index a4a0996a726..41697faeaca 100644 --- a/lisp/subr.el +++ b/lisp/subr.el | |||
| @@ -238,7 +238,7 @@ letter but *do not* end with a period. Please follow this convention | |||
| 238 | for the sake of consistency." | 238 | for the sake of consistency." |
| 239 | (while t | 239 | (while t |
| 240 | (signal 'error (list (apply 'format args))))) | 240 | (signal 'error (list (apply 'format args))))) |
| 241 | (set-advertised-calling-convention 'error '(string &rest args)) | 241 | (set-advertised-calling-convention 'error '(string &rest args) "23.1") |
| 242 | 242 | ||
| 243 | ;; We put this here instead of in frame.el so that it's defined even on | 243 | ;; We put this here instead of in frame.el so that it's defined even on |
| 244 | ;; systems where frame.el isn't loaded. | 244 | ;; systems where frame.el isn't loaded. |
| @@ -1038,9 +1038,10 @@ is converted into a string by expressing it in decimal." | |||
| 1038 | (make-obsolete 'make-variable-frame-local | 1038 | (make-obsolete 'make-variable-frame-local |
| 1039 | "explicitly check for a frame-parameter instead." "22.2") | 1039 | "explicitly check for a frame-parameter instead." "22.2") |
| 1040 | (make-obsolete 'interactive-p 'called-interactively-p "23.2") | 1040 | (make-obsolete 'interactive-p 'called-interactively-p "23.2") |
| 1041 | (set-advertised-calling-convention 'called-interactively-p '(kind)) | 1041 | (set-advertised-calling-convention 'called-interactively-p '(kind) "23.1") |
| 1042 | (set-advertised-calling-convention | 1042 | (set-advertised-calling-convention |
| 1043 | 'all-completions '(string collection &optional predicate)) | 1043 | 'all-completions '(string collection &optional predicate) "23.1") |
| 1044 | (set-advertised-calling-convention 'unintern '(name obarray) "23.3") | ||
| 1044 | 1045 | ||
| 1045 | ;;;; Obsolescence declarations for variables, and aliases. | 1046 | ;;;; Obsolescence declarations for variables, and aliases. |
| 1046 | 1047 | ||
| @@ -2061,7 +2062,7 @@ floating point support." | |||
| 2061 | (setq read (cons t read))) | 2062 | (setq read (cons t read))) |
| 2062 | (push read unread-command-events) | 2063 | (push read unread-command-events) |
| 2063 | nil)))))) | 2064 | nil)))))) |
| 2064 | (set-advertised-calling-convention 'sit-for '(seconds &optional nodisp)) | 2065 | (set-advertised-calling-convention 'sit-for '(seconds &optional nodisp) "22.1") |
| 2065 | 2066 | ||
| 2066 | ;;; Atomic change groups. | 2067 | ;;; Atomic change groups. |
| 2067 | 2068 | ||
| @@ -2589,7 +2590,7 @@ discouraged." | |||
| 2589 | (start-process name buffer shell-file-name shell-command-switch | 2590 | (start-process name buffer shell-file-name shell-command-switch |
| 2590 | (mapconcat 'identity args " "))) | 2591 | (mapconcat 'identity args " "))) |
| 2591 | (set-advertised-calling-convention 'start-process-shell-command | 2592 | (set-advertised-calling-convention 'start-process-shell-command |
| 2592 | '(name buffer command)) | 2593 | '(name buffer command) "23.1") |
| 2593 | 2594 | ||
| 2594 | (defun start-file-process-shell-command (name buffer &rest args) | 2595 | (defun start-file-process-shell-command (name buffer &rest args) |
| 2595 | "Start a program in a subprocess. Return the process object for it. | 2596 | "Start a program in a subprocess. Return the process object for it. |
| @@ -2600,7 +2601,7 @@ Similar to `start-process-shell-command', but calls `start-file-process'." | |||
| 2600 | (if (file-remote-p default-directory) "-c" shell-command-switch) | 2601 | (if (file-remote-p default-directory) "-c" shell-command-switch) |
| 2601 | (mapconcat 'identity args " "))) | 2602 | (mapconcat 'identity args " "))) |
| 2602 | (set-advertised-calling-convention 'start-file-process-shell-command | 2603 | (set-advertised-calling-convention 'start-file-process-shell-command |
| 2603 | '(name buffer command)) | 2604 | '(name buffer command) "23.1") |
| 2604 | 2605 | ||
| 2605 | (defun call-process-shell-command (command &optional infile buffer display | 2606 | (defun call-process-shell-command (command &optional infile buffer display |
| 2606 | &rest args) | 2607 | &rest args) |