eschulte pushed a commit to branch go
in repository elpa.
commit 96bc62bee973c27c4847eda66976a88c7c16811d
Author: Eric Schulte <[email protected]>
Date: Thu Aug 8 10:52:36 2013 -0600
use igs-re-cond to handle prompts
---
back-ends/igs.el | 8 +++-----
1 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/back-ends/igs.el b/back-ends/igs.el
index f012090..7173086 100644
--- a/back-ends/igs.el
+++ b/back-ends/igs.el
@@ -135,10 +135,8 @@ This is used to re-send messages to keep the IGS server
from timing out.")
(content (match-string 2 string)))
(case type
(:prompt
- (case (if *igs-last-command*
- (intern (concat ":" (downcase *igs-last-command*)))
- :none)
- (:games (igs-list-games *igs-instance* *igs-games*))
+ (igs-re-cond (or *igs-last-command* "")
+ ("^games" (igs-list-games *igs-instance* *igs-games*))
(t nil))
(setq *igs-last-command* nil))
(:info (unless (string= content "yes")
@@ -259,7 +257,7 @@ This is used to re-send messages to keep the IGS server
from timing out.")
(declare (indent 1))
`(cond ,@(mapcar
(lambda (part)
- (cons (if (or (keywordp (car part)))
+ (cons (if (or (keywordp (car part)) (eq t (car part)))
(car part)
`(string-match ,(car part) ,string))
(cdr part)))