changeset 108876:d81856a405a6

* net/rcirc.el (rcirc-sort-nicknames): Change default. (rcirc-sort-nicknames-join): Avoid setq.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Thu, 03 Jun 2010 11:51:38 -0400
parents d01ede419552
children 122187b88e6f
files lisp/ChangeLog lisp/net/rcirc.el
diffstat 2 files changed, 10 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Thu Jun 03 11:07:49 2010 -0400
+++ b/lisp/ChangeLog	Thu Jun 03 11:51:38 2010 -0400
@@ -1,3 +1,8 @@
+2010-06-03  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* net/rcirc.el (rcirc-sort-nicknames): Change default.
+	(rcirc-sort-nicknames-join): Avoid setq.
+
 2010-06-03  Deniz Dogan  <deniz.a.m.dogan@gmail.com>
 
 	* net/rcirc.el (rcirc-sort-nicknames): New custom.
--- a/lisp/net/rcirc.el	Thu Jun 03 11:07:49 2010 -0400
+++ b/lisp/net/rcirc.el	Thu Jun 03 11:51:38 2010 -0400
@@ -281,7 +281,8 @@
   :type 'hook
   :group 'rcirc)
 
-(defcustom rcirc-sort-nicknames nil
+;; Does this really merit a config variable?
+(defcustom rcirc-sort-nicknames t
   "If non-nil, sorts nickname listings."
   :type 'boolean
   :group 'rcirc)
@@ -1682,10 +1683,9 @@
 INPUT is a string containing nicknames separated by SEP.
 
 This function is non-destructive, sorting a copy of the input."
-  (let ((parts (split-string input sep t))
-        copy)
-    (setq copy (sort parts 'rcirc-nickname<))
-    (mapconcat 'identity copy sep)))
+  (let* ((parts (split-string input sep t))
+         (sorted (sort parts 'rcirc-nickname<)))
+    (mapconcat 'identity sorted sep)))
 
 ;;; activity tracking
 (defvar rcirc-track-minor-mode-map (make-sparse-keymap)