diff options
| author | Lars Ingebrigtsen | 2016-02-12 15:08:20 +1100 |
|---|---|---|
| committer | Lars Ingebrigtsen | 2016-02-12 15:08:20 +1100 |
| commit | 4f8de080ef9bd6417fa99560f8bf9f3e7cc4d28b (patch) | |
| tree | ee2f63e1b4270b823c6e72622df34e5e6abd7bcb | |
| parent | 9f7711815b808d69f74af93c5a7a36ae6a73900c (diff) | |
| download | emacs-4f8de080ef9bd6417fa99560f8bf9f3e7cc4d28b.tar.gz emacs-4f8de080ef9bd6417fa99560f8bf9f3e7cc4d28b.zip | |
Remove XEmacs compat code from Gnus helper libraries
* lisp/gnus/plstore.el (plstore-called-interactively-p): Remove.
* lisp/gnus/pop3.el (pop3-make-date): Remove XEmacs compat.
* lisp/gnus/sieve-mode.el: Remove XEmacs compat.
* lisp/gnus/spam-stat.el (spam-stat-called-interactively-p): Remove.
| -rw-r--r-- | lisp/gnus/plstore.el | 14 | ||||
| -rw-r--r-- | lisp/gnus/pop3.el | 4 | ||||
| -rw-r--r-- | lisp/gnus/rfc1843.el | 1 | ||||
| -rw-r--r-- | lisp/gnus/rfc2047.el | 4 | ||||
| -rw-r--r-- | lisp/gnus/sieve-mode.el | 5 | ||||
| -rw-r--r-- | lisp/gnus/smime.el | 10 | ||||
| -rw-r--r-- | lisp/gnus/spam-stat.el | 14 | ||||
| -rw-r--r-- | lisp/gnus/yenc.el | 4 |
8 files changed, 11 insertions, 45 deletions
diff --git a/lisp/gnus/plstore.el b/lisp/gnus/plstore.el index e327bbd4846..5685590a446 100644 --- a/lisp/gnus/plstore.el +++ b/lisp/gnus/plstore.el | |||
| @@ -554,18 +554,6 @@ If no one is selected, symmetric encryption will be performed. " | |||
| 554 | (plstore-mode-original) | 554 | (plstore-mode-original) |
| 555 | (plstore-mode-decoded))) | 555 | (plstore-mode-decoded))) |
| 556 | 556 | ||
| 557 | (eval-when-compile | ||
| 558 | (defmacro plstore-called-interactively-p (kind) | ||
| 559 | (condition-case nil | ||
| 560 | (progn | ||
| 561 | (eval '(called-interactively-p 'any)) | ||
| 562 | ;; Emacs >=23.2 | ||
| 563 | `(called-interactively-p ,kind)) | ||
| 564 | ;; Emacs <23.2 | ||
| 565 | (wrong-number-of-arguments '(called-interactively-p)) | ||
| 566 | ;; XEmacs | ||
| 567 | (void-function '(interactive-p))))) | ||
| 568 | |||
| 569 | ;;;###autoload | 557 | ;;;###autoload |
| 570 | (define-derived-mode plstore-mode emacs-lisp-mode "PLSTORE" | 558 | (define-derived-mode plstore-mode emacs-lisp-mode "PLSTORE" |
| 571 | "Major mode for editing PLSTORE files." | 559 | "Major mode for editing PLSTORE files." |
| @@ -573,7 +561,7 @@ If no one is selected, symmetric encryption will be performed. " | |||
| 573 | (add-hook 'write-contents-functions #'plstore--write-contents-functions) | 561 | (add-hook 'write-contents-functions #'plstore--write-contents-functions) |
| 574 | (define-key plstore-mode-map "\C-c\C-c" #'plstore-mode-toggle-display) | 562 | (define-key plstore-mode-map "\C-c\C-c" #'plstore-mode-toggle-display) |
| 575 | ;; to create a new file with plstore-mode, mark it as already decoded | 563 | ;; to create a new file with plstore-mode, mark it as already decoded |
| 576 | (if (plstore-called-interactively-p 'any) | 564 | (if (called-interactively-p 'any) |
| 577 | (setq plstore-encoded t) | 565 | (setq plstore-encoded t) |
| 578 | (plstore-mode-decoded))) | 566 | (plstore-mode-decoded))) |
| 579 | 567 | ||
diff --git a/lisp/gnus/pop3.el b/lisp/gnus/pop3.el index fc593806bfc..41ebe986220 100644 --- a/lisp/gnus/pop3.el +++ b/lisp/gnus/pop3.el | |||
| @@ -644,9 +644,7 @@ If NOW, use that time instead." | |||
| 644 | (format " %s " | 644 | (format " %s " |
| 645 | (capitalize (car (rassoc (nth 4 (decode-time now)) | 645 | (capitalize (car (rassoc (nth 4 (decode-time now)) |
| 646 | parse-time-months)))) | 646 | parse-time-months)))) |
| 647 | (format-time-string "%Y %H:%M:%S " now) | 647 | (format-time-string "%Y %H:%M:%S %z" now)))) |
| 648 | ;; We do all of this because XEmacs doesn't have the %z spec. | ||
| 649 | (format "%s%02d%02d" sign (/ zone 3600) (/ (% zone 3600) 60))))) | ||
| 650 | 648 | ||
| 651 | (defun pop3-munge-message-separator (start end) | 649 | (defun pop3-munge-message-separator (start end) |
| 652 | "Check to see if a message separator exists. If not, generate one." | 650 | "Check to see if a message separator exists. If not, generate one." |
diff --git a/lisp/gnus/rfc1843.el b/lisp/gnus/rfc1843.el index 81646b4e196..ee2af4803f6 100644 --- a/lisp/gnus/rfc1843.el +++ b/lisp/gnus/rfc1843.el | |||
| @@ -90,7 +90,6 @@ ftp://ftp.math.psu.edu/pub/simpson/chinese/hzp/hzp.doc" | |||
| 90 | (while (re-search-forward (if rfc1843-decode-hzp | 90 | (while (re-search-forward (if rfc1843-decode-hzp |
| 91 | rfc1843-hzp-word-regexp | 91 | rfc1843-hzp-word-regexp |
| 92 | rfc1843-word-regexp) (point-max) t) | 92 | rfc1843-word-regexp) (point-max) t) |
| 93 | ;;; Text with extents may cause XEmacs crash | ||
| 94 | (setq str (buffer-substring-no-properties | 93 | (setq str (buffer-substring-no-properties |
| 95 | (match-beginning 1) | 94 | (match-beginning 1) |
| 96 | (match-end 1))) | 95 | (match-end 1))) |
diff --git a/lisp/gnus/rfc2047.el b/lisp/gnus/rfc2047.el index be491e9db99..2862bb3a810 100644 --- a/lisp/gnus/rfc2047.el +++ b/lisp/gnus/rfc2047.el | |||
| @@ -356,9 +356,7 @@ The buffer may be narrowed." | |||
| 356 | ;; it appears to be the cleanest way. | 356 | ;; it appears to be the cleanest way. |
| 357 | ;; Play safe and don't assume the form of the word syntax entry -- | 357 | ;; Play safe and don't assume the form of the word syntax entry -- |
| 358 | ;; copy it from ?a. | 358 | ;; copy it from ?a. |
| 359 | (if (featurep 'xemacs) | 359 | (set-char-table-range table t (aref (standard-syntax-table) ?a)) |
| 360 | (put-char-table t (get-char-table ?a (standard-syntax-table)) table) | ||
| 361 | (set-char-table-range table t (aref (standard-syntax-table) ?a))) | ||
| 362 | (modify-syntax-entry ?\\ "\\" table) | 360 | (modify-syntax-entry ?\\ "\\" table) |
| 363 | (modify-syntax-entry ?\" "\"" table) | 361 | (modify-syntax-entry ?\" "\"" table) |
| 364 | (modify-syntax-entry ?\( "(" table) | 362 | (modify-syntax-entry ?\( "(" table) |
diff --git a/lisp/gnus/sieve-mode.el b/lisp/gnus/sieve-mode.el index 5ea687dd918..7575ba67c5e 100644 --- a/lisp/gnus/sieve-mode.el +++ b/lisp/gnus/sieve-mode.el | |||
| @@ -204,9 +204,8 @@ Turning on Sieve mode runs `sieve-mode-hook'." | |||
| 204 | (set (make-local-variable 'comment-end) "") | 204 | (set (make-local-variable 'comment-end) "") |
| 205 | ;;(set (make-local-variable 'comment-start-skip) "\\(^\\|\\s-\\);?#+ *") | 205 | ;;(set (make-local-variable 'comment-start-skip) "\\(^\\|\\s-\\);?#+ *") |
| 206 | (set (make-local-variable 'comment-start-skip) "#+ *") | 206 | (set (make-local-variable 'comment-start-skip) "#+ *") |
| 207 | (unless (featurep 'xemacs) | 207 | (set (make-local-variable 'font-lock-defaults) |
| 208 | (set (make-local-variable 'font-lock-defaults) | 208 | '(sieve-font-lock-keywords nil nil ((?_ . "w")))) |
| 209 | '(sieve-font-lock-keywords nil nil ((?_ . "w"))))) | ||
| 210 | (easy-menu-add-item nil nil sieve-mode-menu)) | 209 | (easy-menu-add-item nil nil sieve-mode-menu)) |
| 211 | 210 | ||
| 212 | ;; Menu | 211 | ;; Menu |
diff --git a/lisp/gnus/smime.el b/lisp/gnus/smime.el index d1077a96fc9..27e3127c0ae 100644 --- a/lisp/gnus/smime.el +++ b/lisp/gnus/smime.el | |||
| @@ -588,13 +588,9 @@ A string or a list of strings is returned." | |||
| 588 | "Get certificate for MAIL from the ldap server at HOST." | 588 | "Get certificate for MAIL from the ldap server at HOST." |
| 589 | (let ((ldapresult | 589 | (let ((ldapresult |
| 590 | (funcall | 590 | (funcall |
| 591 | (if (featurep 'xemacs) | 591 | (progn |
| 592 | (progn | 592 | (require 'ldap) |
| 593 | (require 'smime-ldap) | 593 | 'ldap-search) |
| 594 | 'smime-ldap-search) | ||
| 595 | (progn | ||
| 596 | (require 'ldap) | ||
| 597 | 'ldap-search)) | ||
| 598 | (concat "mail=" mail) | 594 | (concat "mail=" mail) |
| 599 | host '("userCertificate") nil)) | 595 | host '("userCertificate") nil)) |
| 600 | (retbuf (generate-new-buffer (format "*certificate for %s*" mail))) | 596 | (retbuf (generate-new-buffer (format "*certificate for %s*" mail))) |
diff --git a/lisp/gnus/spam-stat.el b/lisp/gnus/spam-stat.el index afcc54137d8..23b4556c759 100644 --- a/lisp/gnus/spam-stat.el +++ b/lisp/gnus/spam-stat.el | |||
| @@ -493,18 +493,6 @@ where DIFF is the difference between SCORE and 0.5." | |||
| 493 | (setcdr (nthcdr 14 result) nil) | 493 | (setcdr (nthcdr 14 result) nil) |
| 494 | result)) | 494 | result)) |
| 495 | 495 | ||
| 496 | (eval-when-compile | ||
| 497 | (defmacro spam-stat-called-interactively-p (kind) | ||
| 498 | (condition-case nil | ||
| 499 | (progn | ||
| 500 | (eval '(called-interactively-p 'any)) | ||
| 501 | ;; Emacs >=23.2 | ||
| 502 | `(called-interactively-p ,kind)) | ||
| 503 | ;; Emacs <23.2 | ||
| 504 | (wrong-number-of-arguments '(called-interactively-p)) | ||
| 505 | ;; XEmacs | ||
| 506 | (void-function '(interactive-p))))) | ||
| 507 | |||
| 508 | (defun spam-stat-score-buffer () | 496 | (defun spam-stat-score-buffer () |
| 509 | "Return a score describing the spam-probability for this buffer. | 497 | "Return a score describing the spam-probability for this buffer. |
| 510 | Add user supplied modifications if supplied." | 498 | Add user supplied modifications if supplied." |
| @@ -522,7 +510,7 @@ Add user supplied modifications if supplied." | |||
| 522 | (error nil))) | 510 | (error nil))) |
| 523 | (ans | 511 | (ans |
| 524 | (if score1s (+ score0 score1s) score0))) | 512 | (if score1s (+ score0 score1s) score0))) |
| 525 | (when (spam-stat-called-interactively-p 'any) | 513 | (when (called-interactively-p 'any) |
| 526 | (message "%S" ans)) | 514 | (message "%S" ans)) |
| 527 | ans)) | 515 | ans)) |
| 528 | 516 | ||
diff --git a/lisp/gnus/yenc.el b/lisp/gnus/yenc.el index cfac06d4f19..a4ebd0db15b 100644 --- a/lisp/gnus/yenc.el +++ b/lisp/gnus/yenc.el | |||
| @@ -90,8 +90,8 @@ | |||
| 90 | (setq last (match-beginning 0)) | 90 | (setq last (match-beginning 0)) |
| 91 | (setq footer-alist (yenc-parse-line (match-string 0))) | 91 | (setq footer-alist (yenc-parse-line (match-string 0))) |
| 92 | (setq work-buffer (generate-new-buffer " *yenc-work*")) | 92 | (setq work-buffer (generate-new-buffer " *yenc-work*")) |
| 93 | (unless (featurep 'xemacs) | 93 | (with-current-buffer work-buffer |
| 94 | (with-current-buffer work-buffer (set-buffer-multibyte nil))) | 94 | (set-buffer-multibyte nil)) |
| 95 | (while (< first last) | 95 | (while (< first last) |
| 96 | (setq char (char-after first)) | 96 | (setq char (char-after first)) |
| 97 | (cond ((or (eq char ?\r) | 97 | (cond ((or (eq char ?\r) |