Using saved parent location: http://bzr.savannah.gnu.org/r/emacs/trunk/ Now on revision 103819. ------------------------------------------------------------ revno: 103819 committer: Daiki Ueno branch nick: trunk timestamp: Mon 2011-04-04 15:16:23 +0900 message: Use lexical binding in ep[ga]*.el. * epa-dired.el: * epa-mail.el: * epa-hook.el: * epa-file.el: * epa.el: * epg.el: Use lexical binding. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2011-04-03 21:23:23 +0000 +++ lisp/ChangeLog 2011-04-04 06:16:23 +0000 @@ -1,3 +1,12 @@ +2011-04-04 Daiki Ueno + + * epa-dired.el: + * epa-mail.el: + * epa-hook.el: + * epa-file.el: + * epa.el: + * epg.el: Use lexical binding. + 2011-04-03 Chong Yidong * dired-aux.el (dired-create-files): Add docstring (Bug#7970). === modified file 'lisp/epa-dired.el' --- lisp/epa-dired.el 2011-01-25 04:08:28 +0000 +++ lisp/epa-dired.el 2011-04-04 06:16:23 +0000 @@ -1,4 +1,4 @@ -;;; epa-dired.el --- the EasyPG Assistant, dired extension +;;; epa-dired.el --- the EasyPG Assistant, dired extension -*- lexical-binding: t -*- ;; Copyright (C) 2006-2011 Free Software Foundation, Inc. ;; Author: Daiki Ueno === modified file 'lisp/epa-file.el' --- lisp/epa-file.el 2011-02-12 23:40:43 +0000 +++ lisp/epa-file.el 2011-04-04 06:16:23 +0000 @@ -1,4 +1,4 @@ -;;; epa-file.el --- the EasyPG Assistant, transparent file encryption +;;; epa-file.el --- the EasyPG Assistant, transparent file encryption -*- lexical-binding: t -*- ;; Copyright (C) 2006-2011 Free Software Foundation, Inc. ;; Author: Daiki Ueno === modified file 'lisp/epa-hook.el' --- lisp/epa-hook.el 2011-01-25 04:08:28 +0000 +++ lisp/epa-hook.el 2011-04-04 06:16:23 +0000 @@ -1,4 +1,4 @@ -;;; epa-hook.el --- preloaded code to enable epa-file.el +;;; epa-hook.el --- preloaded code to enable epa-file.el -*- lexical-binding: t -*- ;; Copyright (C) 2006-2011 Free Software Foundation, Inc. ;; Author: Daiki Ueno === modified file 'lisp/epa-mail.el' --- lisp/epa-mail.el 2011-01-25 04:08:28 +0000 +++ lisp/epa-mail.el 2011-04-04 06:16:23 +0000 @@ -1,4 +1,4 @@ -;;; epa-mail.el --- the EasyPG Assistant, minor-mode for mail composer +;;; epa-mail.el --- the EasyPG Assistant, minor-mode for mail composer -*- lexical-binding: t -*- ;; Copyright (C) 2006-2011 Free Software Foundation, Inc. ;; Author: Daiki Ueno @@ -117,7 +117,7 @@ (save-excursion (let ((verbose current-prefix-arg) (context (epg-make-context epa-protocol)) - recipients-string recipients recipient-key) + recipients-string recipients recipient-key sign) (goto-char (point-min)) (save-restriction (narrow-to-region (point) === modified file 'lisp/epa.el' --- lisp/epa.el 2011-01-26 08:36:39 +0000 +++ lisp/epa.el 2011-04-04 06:16:23 +0000 @@ -1,4 +1,4 @@ -;;; epa.el --- the EasyPG Assistant +;;; epa.el --- the EasyPG Assistant -*- lexical-binding: t -*- ;; Copyright (C) 2006-2011 Free Software Foundation, Inc. @@ -269,7 +269,7 @@ :action 'epa--key-widget-action :help-echo 'epa--key-widget-help-echo) -(defun epa--key-widget-action (widget &optional event) +(defun epa--key-widget-action (widget &optional _event) (save-selected-window (epa--show-key (widget-get widget :value)))) @@ -460,7 +460,7 @@ (list nil))) (epa--list-keys name t)) -(defun epa--key-list-revert-buffer (&optional ignore-auto noconfirm) +(defun epa--key-list-revert-buffer (&optional _ignore-auto _noconfirm) (apply #'epa--list-keys epa-list-keys-arguments)) (defun epa--marked-keys () @@ -490,13 +490,13 @@ - `\\[epa-mark-key]' to mark a key on the line - `\\[epa-unmark-key]' to unmark a key on the line\n")) (widget-create 'link - :notify (lambda (&rest ignore) (abort-recursive-edit)) + :notify (lambda (&rest _ignore) (abort-recursive-edit)) :help-echo (substitute-command-keys "Click here or \\[abort-recursive-edit] to cancel") "Cancel") (widget-create 'link - :notify (lambda (&rest ignore) (exit-recursive-edit)) + :notify (lambda (&rest _ignore) (exit-recursive-edit)) :help-echo (substitute-command-keys "Click here or \\[exit-recursive-edit] to finish") @@ -649,7 +649,7 @@ (format "Passphrase for %s %s: " key-id (cdr entry)) (format "Passphrase for %s: " key-id))))))) -(defun epa-progress-callback-function (context what char current total +(defun epa-progress-callback-function (_context what _char current total handback) (message "%s%d%% (%d/%d)" (or handback (concat what ": ")) @@ -964,7 +964,7 @@ (eval-and-compile (if (fboundp 'select-safe-coding-system) (defalias 'epa--select-safe-coding-system 'select-safe-coding-system) - (defun epa--select-safe-coding-system (from to) + (defun epa--select-safe-coding-system (_from _to) buffer-file-coding-system))) ;;;###autoload === modified file 'lisp/epg.el' --- lisp/epg.el 2011-02-12 23:40:43 +0000 +++ lisp/epg.el 2011-04-04 06:16:23 +0000 @@ -1,4 +1,4 @@ -;;; epg.el --- the EasyPG Library +;;; epg.el --- the EasyPG Library -*- lexical-binding: t -*- ;; Copyright (C) 1999-2000, 2002-2011 Free Software Foundation, Inc. ;; Author: Daiki Ueno @@ -1223,7 +1223,7 @@ (defalias 'epg--decode-coding-string 'decode-coding-string) (defalias 'epg--decode-coding-string 'identity))) -(defun epg--status-USERID_HINT (context string) +(defun epg--status-USERID_HINT (_context string) (if (string-match "\\`\\([^ ]+\\) \\(.*\\)" string) (let* ((key-id (match-string 1 string)) (user-id (match-string 2 string)) @@ -1238,14 +1238,14 @@ (setq epg-user-id-alist (cons (cons key-id user-id) epg-user-id-alist)))))) -(defun epg--status-NEED_PASSPHRASE (context string) +(defun epg--status-NEED_PASSPHRASE (_context string) (if (string-match "\\`\\([^ ]+\\)" string) (setq epg-key-id (match-string 1 string)))) -(defun epg--status-NEED_PASSPHRASE_SYM (context string) +(defun epg--status-NEED_PASSPHRASE_SYM (_context _string) (setq epg-key-id 'SYM)) -(defun epg--status-NEED_PASSPHRASE_PIN (context string) +(defun epg--status-NEED_PASSPHRASE_PIN (_context _string) (setq epg-key-id 'PIN)) (eval-and-compile @@ -1308,11 +1308,11 @@ (if encoded-passphrase-with-new-line (epg--clear-string encoded-passphrase-with-new-line)))))) -(defun epg--prompt-GET_BOOL (context string) +(defun epg--prompt-GET_BOOL (_context string) (let ((entry (assoc string epg-prompt-alist))) (y-or-n-p (if entry (cdr entry) (concat string "? "))))) -(defun epg--prompt-GET_BOOL-untrusted_key.override (context string) +(defun epg--prompt-GET_BOOL-untrusted_key.override (_context _string) (y-or-n-p (if (and (equal (car epg-last-status) "USERID_HINT") (string-match "\\`\\([^ ]+\\) \\(.*\\)" (cdr epg-last-status))) @@ -1467,31 +1467,31 @@ signature (string-to-number (match-string 7 string) 16))))) -(defun epg--status-TRUST_UNDEFINED (context string) +(defun epg--status-TRUST_UNDEFINED (context _string) (let ((signature (car (epg-context-result-for context 'verify)))) (if (and signature (eq (epg-signature-status signature) 'good)) (epg-signature-set-validity signature 'undefined)))) -(defun epg--status-TRUST_NEVER (context string) +(defun epg--status-TRUST_NEVER (context _string) (let ((signature (car (epg-context-result-for context 'verify)))) (if (and signature (eq (epg-signature-status signature) 'good)) (epg-signature-set-validity signature 'never)))) -(defun epg--status-TRUST_MARGINAL (context string) +(defun epg--status-TRUST_MARGINAL (context _string) (let ((signature (car (epg-context-result-for context 'verify)))) (if (and signature (eq (epg-signature-status signature) 'marginal)) (epg-signature-set-validity signature 'marginal)))) -(defun epg--status-TRUST_FULLY (context string) +(defun epg--status-TRUST_FULLY (context _string) (let ((signature (car (epg-context-result-for context 'verify)))) (if (and signature (eq (epg-signature-status signature) 'good)) (epg-signature-set-validity signature 'full)))) -(defun epg--status-TRUST_ULTIMATE (context string) +(defun epg--status-TRUST_ULTIMATE (context _string) (let ((signature (car (epg-context-result-for context 'verify)))) (if (and signature (eq (epg-signature-status signature) 'good)) @@ -1541,10 +1541,10 @@ (string-to-number (match-string 3 string))) (epg-context-result-for context 'encrypted-to))))) -(defun epg--status-DECRYPTION_FAILED (context string) +(defun epg--status-DECRYPTION_FAILED (context _string) (epg-context-set-result-for context 'decryption-failed t)) -(defun epg--status-DECRYPTION_OKAY (context string) +(defun epg--status-DECRYPTION_OKAY (context _string) (epg-context-set-result-for context 'decryption-okay t)) (defun epg--status-NODATA (context string) @@ -1566,13 +1566,13 @@ (epg--time-from-seconds string))) (epg-context-result-for context 'error)))) -(defun epg--status-KEYREVOKED (context string) +(defun epg--status-KEYREVOKED (context _string) (epg-context-set-result-for context 'key (cons '(key-revoked) (epg-context-result-for context 'error)))) -(defun epg--status-BADARMOR (context string) +(defun epg--status-BADARMOR (context _string) (epg-context-set-result-for context 'error (cons '(bad-armor) @@ -1589,7 +1589,7 @@ (match-string 2 string))) (epg-context-result-for context 'error))))) -(defun epg--status-NO_RECP (context string) +(defun epg--status-NO_RECP (context _string) (epg-context-set-result-for context 'error (cons '(no-recipients) @@ -1626,13 +1626,13 @@ (cons 'fingerprint (match-string 2 string))) (epg-context-result-for context 'generate-key))))) -(defun epg--status-KEY_NOT_CREATED (context string) +(defun epg--status-KEY_NOT_CREATED (context _string) (epg-context-set-result-for context 'error (cons '(key-not-created) (epg-context-result-for context 'error)))) -(defun epg--status-IMPORTED (context string) +(defun epg--status-IMPORTED (_context string) (if (string-match "\\`\\([^ ]+\\) \\(.*\\)" string) (let* ((key-id (match-string 1 string)) (user-id (match-string 2 string)) @@ -1694,7 +1694,7 @@ (epg-context-result-for context 'import-status))) (epg-context-set-result-for context 'import-status nil))) -(defun epg-passphrase-callback-function (context key-id handback) +(defun epg-passphrase-callback-function (context key-id _handback) (if (eq key-id 'SYM) (read-passwd "Passphrase for symmetric encryption: " (eq (epg-context-operation context) 'encrypt)) ------------------------------------------------------------ revno: 103818 committer: Stefan Monnier branch nick: trunk timestamp: Sun 2011-04-03 21:10:13 -0400 message: * src/keyboard.c (safe_run_hook_funcall): Fix last change (don't stop at the first non-nil return value). diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2011-04-03 08:30:57 +0000 +++ src/ChangeLog 2011-04-04 01:10:13 +0000 @@ -1,3 +1,8 @@ +2011-04-04 Stefan Monnier + + * keyboard.c (safe_run_hook_funcall): Fix last change (don't stop at the + first non-nil return value). + 2011-04-03 Jan Djärv * nsterm.m (ns_update_auto_hide_menu_bar): Define MAC_OS_X_VERSION_10_6 === modified file 'src/keyboard.c' --- src/keyboard.c 2011-03-31 04:24:03 +0000 +++ src/keyboard.c 2011-04-04 01:10:13 +0000 @@ -1870,7 +1870,8 @@ else Vinhibit_quit = Fcons (Vinhibit_quit, args[0]); - return internal_condition_case (safe_run_hooks_1, Qt, safe_run_hooks_error); + internal_condition_case (safe_run_hooks_1, Qt, safe_run_hooks_error); + return Qnil; } /* If we get an error while running the hook, cause the hook variable ------------------------------------------------------------ revno: 103817 committer: Chong Yidong branch nick: trunk timestamp: Sun 2011-04-03 17:23:23 -0400 message: * lisp/dired-aux.el (dired-create-files): Add docstring (Bug#7970). diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2011-04-03 20:59:45 +0000 +++ lisp/ChangeLog 2011-04-03 21:23:23 +0000 @@ -1,5 +1,7 @@ 2011-04-03 Chong Yidong + * dired-aux.el (dired-create-files): Add docstring (Bug#7970). + * textmodes/flyspell.el (flyspell-word): Recognize default dictionary case for flyspell-mark-duplications-exceptions. Use regexp matching for languages. === modified file 'lisp/dired-aux.el' --- lisp/dired-aux.el 2011-03-19 22:07:41 +0000 +++ lisp/dired-aux.el 2011-04-03 21:23:23 +0000 @@ -1363,33 +1363,28 @@ ;; The basic function for half a dozen variations on cp/mv/ln/ln -s. (defun dired-create-files (file-creator operation fn-list name-constructor &optional marker-char) - -;; Create a new file for each from a list of existing files. The user -;; is queried, dired buffers are updated, and at the end a success or -;; failure message is displayed - -;; FILE-CREATOR must accept three args: oldfile newfile ok-if-already-exists - -;; It is called for each file and must create newfile, the entry of -;; which will be added. The user will be queried if the file already -;; exists. If oldfile is removed by FILE-CREATOR (i.e, it is a -;; rename), it is FILE-CREATOR's responsibility to update dired -;; buffers. FILE-CREATOR must abort by signaling a file-error if it -;; could not create newfile. The error is caught and logged. - -;; OPERATION (a capitalized string, e.g. `Copy') describes the -;; operation performed. It is used for error logging. - -;; FN-LIST is the list of files to copy (full absolute file names). - -;; NAME-CONSTRUCTOR returns a newfile for every oldfile, or nil to -;; skip. If it skips files for other reasons than a direct user -;; query, it is supposed to tell why (using dired-log). - -;; Optional MARKER-CHAR is a character with which to mark every -;; newfile's entry, or t to use the current marker character if the -;; oldfile was marked. - + "Create one or more new files from a list of existing files FN-LIST. +This function also handles querying the user, updating Dired +buffers, and displaying a success or failure message. + +FILE-CREATOR should be a function. It is called once for each +file in FN-LIST, and must create a new file, querying the user +and updating Dired buffers as necessary. It should accept three +arguments: the old file name, the new name, and an argument +OK-IF-ALREADY-EXISTS with the same meaning as in `copy-file'. + +OPERATION should be a capitalized string describing the operation +performed (e.g. `Copy'). It is used for error logging. + +FN-LIST is the list of files to copy (full absolute file names). + +NAME-CONSTRUCTOR should be a function accepting a single +argument, the name of an old file, and returning either the +corresponding new file name or nil to skip. + +Optional MARKER-CHAR is a character with which to mark every +newfile's entry, or t to use the current marker character if the +old file was marked." (let (dired-create-files-failures failures skipped (success-count 0) (total (length fn-list))) (let (to overwrite-query ------------------------------------------------------------ revno: 103816 committer: Chong Yidong branch nick: trunk timestamp: Sun 2011-04-03 17:06:47 -0400 message: Add changes to lisp/url/ChangeLog omitted from r103811. diff: === modified file 'lisp/url/ChangeLog' --- lisp/url/ChangeLog 2011-04-02 18:53:37 +0000 +++ lisp/url/ChangeLog 2011-04-03 21:06:47 +0000 @@ -1,3 +1,8 @@ +2011-04-02 Chong Yidong + + * url-gw.el (url-open-stream): Use new open-network-stream + functionality to perform encryption. + 2011-04-01 Juanma Barranquero * url-cookie.el (url-cookie-handle-set-cookie): ------------------------------------------------------------ revno: 103815 committer: Chong Yidong branch nick: trunk timestamp: Sun 2011-04-03 16:59:45 -0400 message: Improvements to flyspell-mark-duplications-exceptions. * lisp/textmodes/flyspell.el (flyspell-word): Recognize default dictionary case for flyspell-mark-duplications-exceptions. Use regexp matching for languages. (flyspell-mark-duplications-exceptions): Add "that" and "had" for default dictionary (Bug#7926). diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2011-04-02 23:41:03 +0000 +++ lisp/ChangeLog 2011-04-03 20:59:45 +0000 @@ -1,3 +1,11 @@ +2011-04-03 Chong Yidong + + * textmodes/flyspell.el (flyspell-word): Recognize default + dictionary case for flyspell-mark-duplications-exceptions. Use + regexp matching for languages. + (flyspell-mark-duplications-exceptions): Add "that" and "had" for + default dictionary (Bug#7926). + 2011-04-02 Chong Yidong * emacs-lisp/package.el (package--with-work-buffer): Recognize === modified file 'lisp/textmodes/flyspell.el' --- lisp/textmodes/flyspell.el 2011-01-25 04:08:28 +0000 +++ lisp/textmodes/flyspell.el 2011-04-03 20:59:45 +0000 @@ -71,13 +71,23 @@ :type 'boolean) (defcustom flyspell-mark-duplications-exceptions - '(("francais" . ("nous" "vous"))) + '((nil . ("that" "had")) ; Common defaults for English. + ("\\`francais" . ("nous" "vous"))) "A list of exceptions for duplicated words. -It should be a list of (LANGUAGE . EXCEPTION-LIST). LANGUAGE is matched -against the current dictionary and EXCEPTION-LIST is a list of strings. -The duplicated word is downcased before it is compared with the exceptions." +It should be a list of (LANGUAGE . EXCEPTION-LIST). + +LANGUAGE is nil, which means the exceptions apply regardless of +the current dictionary, or a regular expression matching the +dictionary name (`ispell-local-dictionary' or +`ispell-dictionary') for which the exceptions should apply. + +EXCEPTION-LIST is a list of strings. The checked word is +downcased before comparing with these exceptions." :group 'flyspell - :type '(alist :key-type string :value-type (repeat string))) + :type '(alist :key-type (choice (const :tag "All dictionaries" nil) + string) + :value-type (repeat string)) + :version "24.1") (defcustom flyspell-sort-corrections nil "Non-nil means, sort the corrections alphabetically before popping them." @@ -1044,12 +1054,14 @@ (not (memq (char-after (1- start)) '(?\} ?\\))))) flyspell-mark-duplications-flag (not (catch 'exception - (dolist (except flyspell-mark-duplications-exceptions) - (and (string= (or ispell-local-dictionary - ispell-dictionary) - (car except)) - (member (downcase word) (cdr except)) - (throw 'exception t))))) + (let ((dict (or ispell-local-dictionary + ispell-dictionary))) + (dolist (except flyspell-mark-duplications-exceptions) + (and (or (null (car except)) + (and (stringp dict) + (string-match (car except) dict))) + (member (downcase word) (cdr except)) + (throw 'exception t)))))) (save-excursion (goto-char start) (let* ((bound ------------------------------------------------------------ revno: 103814 committer: Jan D. branch nick: trunk timestamp: Sun 2011-04-03 10:30:57 +0200 message: * nsterm.m (ns_update_auto_hide_menu_bar): Define MAC_OS_X_VERSION_10_6 if not defined. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2011-04-02 23:53:55 +0000 +++ src/ChangeLog 2011-04-03 08:30:57 +0000 @@ -1,3 +1,8 @@ +2011-04-03 Jan Djärv + + * nsterm.m (ns_update_auto_hide_menu_bar): Define MAC_OS_X_VERSION_10_6 + if not defined (Bug#8403). + 2011-04-02 Juanma Barranquero * xdisp.c (display_count_lines): Remove parameter `start', === modified file 'src/nsterm.m' --- src/nsterm.m 2011-04-02 07:11:00 +0000 +++ src/nsterm.m 2011-04-03 08:30:57 +0000 @@ -583,6 +583,9 @@ static void ns_update_auto_hide_menu_bar (void) { +#ifndef MAC_OS_X_VERSION_10_6 +#define MAC_OS_X_VERSION_10_6 1060 +#endif #ifdef NS_IMPL_COCOA #if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_6 BLOCK_INPUT; ------------------------------------------------------------ revno: 103813 committer: Chong Yidong branch nick: trunk timestamp: Sat 2011-04-02 20:40:35 -0400 message: Fix missing NEWS subentry (Bug#8400). diff: === modified file 'etc/NEWS' --- etc/NEWS 2011-04-02 23:41:03 +0000 +++ etc/NEWS 2011-04-03 00:40:35 +0000 @@ -349,6 +349,7 @@ *** To return to the previous behavior, do the following: +**** Change `select-active-regions' to nil. **** Change `mouse-drag-copy-region' to t. **** Change `x-select-enable-primary' to t (on X only). **** Change `x-select-enable-clipboard' to nil.