Mercurial > emacs
comparison lisp/abbrev.el @ 87754:2957493cf354
(clear-abbrev-table): Can't pass a symbol to intern.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Mon, 14 Jan 2008 20:17:52 +0000 |
parents | 107ccd98fa12 |
children | c70e45a7acfd 73a01bf5cb80 |
comparison
equal
deleted
inserted
replaced
87753:5e9cb28bbc5c | 87754:2957493cf354 |
---|---|
522 (let* ((sym (intern-soft "" table))) | 522 (let* ((sym (intern-soft "" table))) |
523 (dotimes (i (length table)) | 523 (dotimes (i (length table)) |
524 (aset table i 0)) | 524 (aset table i 0)) |
525 ;; Preserve the table's properties. | 525 ;; Preserve the table's properties. |
526 (assert sym) | 526 (assert sym) |
527 (intern sym table) | 527 (let ((newsym (intern "" table))) |
528 (set newsym nil) ; Make sure it won't be confused for an abbrev. | |
529 (setplist newsym (symbol-plist sym))) | |
528 (abbrev-table-put table :abbrev-table-modiff | 530 (abbrev-table-put table :abbrev-table-modiff |
529 (1+ (abbrev-table-get table :abbrev-table-modiff))))) | 531 (1+ (abbrev-table-get table :abbrev-table-modiff))))) |
530 | 532 |
531 (defun define-abbrev (table name expansion &optional hook &rest props) | 533 (defun define-abbrev (table name expansion &optional hook &rest props) |
532 "Define an abbrev in TABLE named NAME, to expand to EXPANSION and call HOOK. | 534 "Define an abbrev in TABLE named NAME, to expand to EXPANSION and call HOOK. |