[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master c00758a 1/2: Remove XEmacs compat code from hashcash.el
From: |
Stefan Kangas |
Subject: |
master c00758a 1/2: Remove XEmacs compat code from hashcash.el |
Date: |
Mon, 26 Oct 2020 20:16:35 -0400 (EDT) |
branch: master
commit c00758a4bca7464250bdd752cb03498ec587e6aa
Author: Stefan Kangas <stefan@marxist.se>
Commit: Stefan Kangas <stefan@marxist.se>
Remove XEmacs compat code from hashcash.el
* lisp/mail/hashcash.el (hashcash-point-at-bol)
(hashcash-point-at-eol): Make obsolete.
(hashcash-token-substring): Don't use the above now obsolete aliases.
---
lisp/mail/hashcash.el | 16 +++++-----------
1 file changed, 5 insertions(+), 11 deletions(-)
diff --git a/lisp/mail/hashcash.el b/lisp/mail/hashcash.el
index 12cffd9..a2705d6 100644
--- a/lisp/mail/hashcash.el
+++ b/lisp/mail/hashcash.el
@@ -116,15 +116,6 @@ For example, you may want to set this to (\"-Z2\") to
reduce header length."
(require 'mail-utils)
-(eval-and-compile
- (if (fboundp 'point-at-bol)
- (defalias 'hashcash-point-at-bol 'point-at-bol)
- (defalias 'hashcash-point-at-bol 'line-beginning-position))
-
- (if (fboundp 'point-at-eol)
- (defalias 'hashcash-point-at-eol 'point-at-eol)
- (defalias 'hashcash-point-at-eol 'line-end-position)))
-
(defun hashcash-strip-quoted-names (addr)
(setq addr (mail-strip-quoted-names addr))
(if (and addr (string-match "\\`\\([^+@]+\\)\\+[^@]*\\(@.+\\)" addr))
@@ -141,8 +132,8 @@ For example, you may want to set this to (\"-Z2\") to
reduce header length."
(let ((token ""))
(cl-loop
(setq token
- (concat token (buffer-substring (point) (hashcash-point-at-eol))))
- (goto-char (hashcash-point-at-eol))
+ (concat token (buffer-substring (point) (line-end-position))))
+ (goto-char (line-end-position))
(forward-char 1)
(unless (looking-at "[ \t]") (cl-return token))
(while (looking-at "[ \t]") (forward-char 1))))))
@@ -374,6 +365,9 @@ Prefix arg sets default accept amount temporarily."
(message "Payment valid"))
ok))))
+(define-obsolete-function-alias 'hashcash-point-at-bol
#'line-beginning-position "28.1")
+(define-obsolete-function-alias 'hashcash-point-at-eol #'line-end-position
"28.1")
+
(provide 'hashcash)
;;; hashcash.el ends here