summaryrefslogtreecommitdiff
path: root/chess-pos.el
diff options
context:
space:
mode:
authorMario Lang <mlang@x4.delysid.org>2009-12-27 20:11:07 +0100
committerMario Lang <mlang@x4.delysid.org>2009-12-27 20:11:07 +0100
commit81c84e9628adf820eea9209e9c0be341a429470a (patch)
tree7d6ca2ca73152ed2ba840e8c916e4a23614ba375 /chess-pos.el
parente84cb965d3bb8e15092e21797c06c60d3db32090 (diff)
char-valid-p is obsolete (as of Emacs 23.1); use characterp instead
Diffstat (limited to 'chess-pos.el')
-rw-r--r--chess-pos.el6
1 files changed, 3 insertions, 3 deletions
diff --git a/chess-pos.el b/chess-pos.el
index 453df5a..4958720 100644
--- a/chess-pos.el
+++ b/chess-pos.el
@@ -705,11 +705,11 @@ If NO-CASTLING is non-nil, do not consider castling moves."
(assert (vectorp position))
(assert (and (>= target 0) (< target 64)))
(assert (memq piece '(t nil ?K ?Q ?N ?B ?R ?P ?k ?q ?n ?b ?r ?p)))
- (let* ((color (if (char-valid-p piece)
+ (let* ((color (if (characterp piece)
(< piece ?a)
piece))
(bias (if color -1 1))
- (test-piece (and (char-valid-p piece)
+ (test-piece (and (characterp piece)
(upcase piece)))
p pos candidates)
(cond
@@ -844,7 +844,7 @@ If NO-CASTLING is non-nil, do not consider castling moves."
;; prune from the discovered candidates list any moves which would
;; leave the king in check; castling through check has already
;; been eliminated.
- (if (and candidates (char-valid-p piece))
+ (if (and candidates (characterp piece))
(setq candidates
(chess-pos-legal-candidates position color target
candidates)))