summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/assoc.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2011-03-06 16:22:16 -0500
committerStefan Monnier <monnier@iro.umontreal.ca>2011-03-06 16:22:16 -0500
commit0d6459dfb52188481bfd6bb53f1b2f653ecd6a5d (patch)
tree306b87fc2903ad23343f3c84be1cccfa72e5a97e /lisp/emacs-lisp/assoc.el
parent798cb64441228d473f7bdd213183c70fb582595c (diff)
parent892777baa1739fa5f1f2d1c2975488c3e6f57bae (diff)
downloademacs-0d6459dfb52188481bfd6bb53f1b2f653ecd6a5d.tar.gz
emacs-0d6459dfb52188481bfd6bb53f1b2f653ecd6a5d.tar.bz2
emacs-0d6459dfb52188481bfd6bb53f1b2f653ecd6a5d.zip
Merge from trunk
Diffstat (limited to 'lisp/emacs-lisp/assoc.el')
-rw-r--r--lisp/emacs-lisp/assoc.el10
1 files changed, 5 insertions, 5 deletions
diff --git a/lisp/emacs-lisp/assoc.el b/lisp/emacs-lisp/assoc.el
index aa85916cc3f..31be851f2dd 100644
--- a/lisp/emacs-lisp/assoc.el
+++ b/lisp/emacs-lisp/assoc.el
@@ -1,4 +1,4 @@
-;;; assoc.el --- insert/delete/sort functions on association lists
+;;; assoc.el --- insert/delete functions on association lists
;; Copyright (C) 1996, 2001-2011 Free Software Foundation, Inc.
@@ -35,7 +35,7 @@ head is one matching KEY. Returns the sorted list and doesn't affect
the order of any other key-value pair. Side effect sets alist to new
sorted list."
(set alist-symbol
- (sort (copy-alist (eval alist-symbol))
+ (sort (copy-alist (symbol-value alist-symbol))
(function (lambda (a b) (equal (car a) key))))))
@@ -75,7 +75,7 @@ of the alist (with value nil if VALUE is nil or not supplied)."
(lexical-let ((elem (aelement key value))
alist)
(asort alist-symbol key)
- (setq alist (eval alist-symbol))
+ (setq alist (symbol-value alist-symbol))
(cond ((null alist) (set alist-symbol elem))
((anot-head-p alist key) (set alist-symbol (nconc elem alist)))
(value (setcar alist (car elem)))
@@ -87,7 +87,7 @@ of the alist (with value nil if VALUE is nil or not supplied)."
Alist is referenced by ALIST-SYMBOL and the key-value pair to remove
is pair matching KEY. Returns the altered alist."
(asort alist-symbol key)
- (lexical-let ((alist (eval alist-symbol)))
+ (lexical-let ((alist (symbol-value alist-symbol)))
(cond ((null alist) nil)
((anot-head-p alist key) alist)
(t (set alist-symbol (cdr alist))))))
@@ -133,7 +133,7 @@ extra values are ignored. Returns the created alist."
(t
(amake alist-symbol keycdr valcdr)
(aput alist-symbol keycar valcar))))
- (eval alist-symbol))
+ (symbol-value alist-symbol))
(provide 'assoc)