/[emacs]/emacs/lisp/mail/mailabbrev.el
ViewVC logotype

Diff of /emacs/lisp/mail/mailabbrev.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.64 by rms, Wed Feb 13 15:59:53 2002 UTC revision 1.65 by rms, Sat Mar 23 16:09:59 2002 UTC
# Line 405  This is not actually made the current sy Line 405  This is not actually made the current sy
405  simply controls the set of characters which may be a part of the name  simply controls the set of characters which may be a part of the name
406  of a mail alias.  The value is set up, buffer-local, when first needed.")  of a mail alias.  The value is set up, buffer-local, when first needed.")
407    
408    (defun mail-abbrev-make-syntax-table ()
409      (make-local-variable 'mail-abbrev-syntax-table)
410      (unless mail-abbrev-syntax-table
411        (let ((tab (copy-syntax-table old-syntax-table))
412              (_ (aref (standard-syntax-table) ?_))
413              (w (aref (standard-syntax-table) ?w)))
414          (map-char-table
415           (function (lambda (key value)
416                       (if (equal value _)
417                           (set-char-table-range tab key w))))
418           tab)
419          (modify-syntax-entry ?@ "w" tab)
420          (setq mail-abbrev-syntax-table tab))))
421    
422  (defun mail-abbrev-in-expansion-header-p ()  (defun mail-abbrev-in-expansion-header-p ()
423    "Whether point is in a mail-address header field."    "Whether point is in a mail-address header field."
# Line 459  of a mail alias.  The value is set up, b Line 472  of a mail alias.  The value is set up, b
472               ;;      expand-abbrev, and not as a result of the call to               ;;      expand-abbrev, and not as a result of the call to
473               ;;      expand-abbrev which invoked *us*.               ;;      expand-abbrev which invoked *us*.
474    
475               (make-local-variable 'mail-abbrev-syntax-table)               (mail-abbrev-make-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)))  
476    
477               ;; If the character just typed was non-alpha-symbol-syntax,               ;; If the character just typed was non-alpha-symbol-syntax,
478               ;; then don't expand the abbrev now (that is, don't expand               ;; then don't expand the abbrev now (that is, don't expand

Legend:
Removed from v.1.64  
changed lines
  Added in v.1.65

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26