]> code.delx.au - gnu-emacs-elpa/commitdiff
* chess-algebraic.el (chess-algebraic-to-ply): Remove dead code.
authorMario Lang <mlang@delysid.org>
Sun, 29 Jun 2014 15:16:37 +0000 (17:16 +0200)
committerMario Lang <mlang@delysid.org>
Sun, 29 Jun 2014 15:16:37 +0000 (17:16 +0200)
ChangeLog
chess-algebraic.el

index e597fa617ab7cc24da382ad8983f013dea678439..935ae2bb15091a8921258b39364d1b63bc4a36b4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2014-06-29  Mario Lang  <mlang@delysid.org>
+
+       * chess-algebraic.el (chess-algebraic-to-ply): Remove dead code.
+
 2014-06-25  Mario Lang  <mlang@delysid.org>
 
        * chess-pos.el (chess-pos-search*)
index 808d3e018f5dc78240f78fe20f732d7a3ba5224f..42b64f108395e97f7f98f56e8f98c13675ca0541 100644 (file)
@@ -138,13 +138,12 @@ This regexp matches short, long and figurine notation.")
                           (list (car candidates) target)
                         (if (null source)
                             (chess-error 'clarify-piece)
-                          (nconc changes (list :which source))
                           (while candidates
                             (if (if (>= source ?a)
                                     (eq (chess-index-file (car candidates))
                                         (- source ?a))
-                                  (eq (chess-index-rank (car candidates))
-                                      (- 7 (- source ?1))))
+                                  (= (chess-index-rank (car candidates))
+                                     (- 7 (- source ?1))))
                                 (setq which (car candidates)
                                       candidates nil)
                               (setq candidates (cdr candidates))))
@@ -220,12 +219,9 @@ Finally, `:numeric' generates ICCF numeric notation (like \"2133\"."
                    (setq rank (1+ rank)))
                  (when (= (chess-index-file candidate) from-file)
                    (setq file (1+ file))))
-               (cond
-                ((= file 1)
-                 (setq differentiator (+ from-file ?a)))
-                ((= rank 1)
-                 (setq differentiator (+ (- 7 from-rank) ?1)))
-                (t (chess-error 'could-not-diff)))
+               (cond ((= file 1) (setq differentiator (+ from-file ?a)))
+                     ((= rank 1) (setq differentiator (+ (- 7 from-rank) ?1)))
+                     (t (chess-error 'could-not-diff)))
                (chess-ply-set-keyword ply :which differentiator))))
          (concat
           (unless (= (upcase from-piece) ?P)