emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] 04/04: [gnugo int] Move vectorizatio n into ‘gnugo--set-tree-ends


From: Thien-Thi Nguyen
Subject: [elpa] 04/04: [gnugo int] Move vectorizatio n into ‘gnugo--set-tree-ends’.
Date: Thu, 10 Apr 2014 05:44:42 +0000

ttn pushed a commit to branch master
in repository elpa.

commit 23890284da439ed50a430683dc369575a2add63a
Author: Thien-Thi Nguyen <address@hidden>
Date:   Thu Apr 10 07:48:44 2014 +0200

    [gnugo int] Move vectorization into ‘gnugo--set-tree-ends’.
    
    * packages/gnugo/gnugo.el (gnugo--set-tree-ends):
    Rename 2nd arg to LS; apply ‘vector’ to it to obtain ENDS.
    (gnugo-frolic-prune-branch, gnugo-note): Update accordingly.
---
 packages/gnugo/gnugo.el |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/packages/gnugo/gnugo.el b/packages/gnugo/gnugo.el
index 3723db9..bf63536 100644
--- a/packages/gnugo/gnugo.el
+++ b/packages/gnugo/gnugo.el
@@ -259,8 +259,8 @@ See `gnugo-put'."
 (defsubst gnugo--tree-ends (tree)
   (aref tree 2))
 
-(defsubst gnugo--set-tree-ends (tree ends)
-  (aset tree 2 ends)
+(defsubst gnugo--set-tree-ends (tree ls)
+  (aset tree 2 (apply 'vector ls))
   ;; hmm, probably unnecessary
   tree)
 
@@ -1068,7 +1068,7 @@ This fails if the monkey is on the current branch
     (let* ((new (append ends nil))
            ;; Gratuitous ‘pop’ rv assignment avoids byte-compiler warning.
            (bye (pop (nthcdr a new))))
-      (gnugo--set-tree-ends tree (apply 'vector new)))
+      (gnugo--set-tree-ends tree new))
     (when (< a bidx)
       (aset monkey 1 (decf bidx)))
     (gnugo-frolic-in-the-leaves)
@@ -1179,7 +1179,7 @@ This fails if the monkey is on the current branch
                 tree (let ((ls (append ends nil)))
                        ;; copy old to the right of new
                        (push mem (nthcdr bidx ls))
-                       (apply 'vector ls))))
+                       ls)))
              (puthash fruit (1+ (gethash tip mnum)) mnum)
              (push fruit mem)
              (aset ends bidx mem)))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]