+2002-03-23 Richard M. Stallman <rms@gnu.org>
+
+ * mail/mailabbrev.el (mail-abbrev-make-syntax-table): New subroutine
+ broken out of sendmail-pre-abbrev-expand-hook.
+ (sendmail-pre-abbrev-expand-hook): Use it.
+
2002-03-22 Stefan Monnier <monnier@cs.yale.edu>
* Makefile.in (finder-inf.el): Remove.
simply controls the set of characters which may be a part of the name
of a mail alias. The value is set up, buffer-local, when first needed.")
+(defun mail-abbrev-make-syntax-table ()
+ (make-local-variable 'mail-abbrev-syntax-table)
+ (unless mail-abbrev-syntax-table
+ (let ((tab (copy-syntax-table old-syntax-table))
+ (_ (aref (standard-syntax-table) ?_))
+ (w (aref (standard-syntax-table) ?w)))
+ (map-char-table
+ (function (lambda (key value)
+ (if (equal value _)
+ (set-char-table-range tab key w))))
+ tab)
+ (modify-syntax-entry ?@ "w" tab)
+ (setq mail-abbrev-syntax-table tab))))
(defun mail-abbrev-in-expansion-header-p ()
"Whether point is in a mail-address header field."
;; expand-abbrev, and not as a result of the call to
;; expand-abbrev which invoked *us*.
- (make-local-variable 'mail-abbrev-syntax-table)
- (unless mail-abbrev-syntax-table
- (let ((tab (copy-syntax-table old-syntax-table))
- (_ (aref (standard-syntax-table) ?_))
- (w (aref (standard-syntax-table) ?w)))
- (map-char-table
- (function (lambda (key value)
- (if (equal value _)
- (set-char-table-range tab key w))))
- tab)
- (modify-syntax-entry ?@ "w" tab)
- (setq mail-abbrev-syntax-table tab)))
+ (mail-abbrev-make-syntax-table)
;; If the character just typed was non-alpha-symbol-syntax,
;; then don't expand the abbrev now (that is, don't expand