aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman2002-09-12 03:19:25 +0000
committerRichard M. Stallman2002-09-12 03:19:25 +0000
commitad9d51b2115f2bfdc4c7cd87c6c8c16cff0729b5 (patch)
tree67adb619147837c38d459b9f24d2f272ecc246b1
parent4af77d9fce153a410a7525f1ab99e84f73145d17 (diff)
downloademacs-ad9d51b2115f2bfdc4c7cd87c6c8c16cff0729b5.tar.gz
emacs-ad9d51b2115f2bfdc4c7cd87c6c8c16cff0729b5.zip
(copy-abbrev-table): New function.
-rw-r--r--lisp/abbrev.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/lisp/abbrev.el b/lisp/abbrev.el
index 25bfcf70585..8e6b3ae69d8 100644
--- a/lisp/abbrev.el
+++ b/lisp/abbrev.el
@@ -74,6 +74,18 @@ buffer."
74 (clear-abbrev-table (symbol-value (car tables))) 74 (clear-abbrev-table (symbol-value (car tables)))
75 (setq tables (cdr tables))))) 75 (setq tables (cdr tables)))))
76 76
77(defun copy-abbrev-table (table)
78 "Make a new abbrev-table with the same abbrevs as TABLE."
79 (let ((new-table (make-abbrev-table)))
80 (mapatoms
81 (lambda (symbol)
82 (define-abbrev new-table
83 (symbol-name symbol)
84 (symbol-value symbol)
85 (symbol-function symbol)))
86 table)
87 new-table))
88
77(defun insert-abbrevs () 89(defun insert-abbrevs ()
78 "Insert after point a description of all defined abbrevs. 90 "Insert after point a description of all defined abbrevs.
79Mark is set after the inserted text." 91Mark is set after the inserted text."