[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/gnugo 5157534 241/357: [gnugo int] Use ‘destructuring-
From: |
Stefan Monnier |
Subject: |
[elpa] externals/gnugo 5157534 241/357: [gnugo int] Use ‘destructuring-bind’ more. |
Date: |
Sun, 29 Nov 2020 14:51:30 -0500 (EST) |
branch: externals/gnugo
commit 515753490d25863c6c70d23c52b0c7208e1909d9
Author: Thien-Thi Nguyen <ttn@gnu.org>
Commit: Thien-Thi Nguyen <ttn@gnu.org>
[gnugo int] Use ‘destructuring-bind’ more.
* packages/gnugo/gnugo.el (gnugo-gate): ...here,
for :waiting check, in the process making it player-agnostic.
---
gnugo.el | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/gnugo.el b/gnugo.el
index ae962fc..7240755 100644
--- a/gnugo.el
+++ b/gnugo.el
@@ -360,12 +360,13 @@ Handle the big, slow-to-render, and/or uninteresting ones
specially."
(user-error "Wrong buffer -- try M-x gnugo"))
(unless (gnugo-get :proc)
(user-error "No \"gnugo\" process!"))
- (let ((slow (gnugo-get :waiting)))
- (when slow
- (gnugo--ERR-wait (gnugo-get :user-color)
- (if (cdr slow)
- "Still thinking"
- "Not your turn yet"))))
+ (destructuring-bind (&optional color . suggestion)
+ (gnugo-get :waiting)
+ (when color
+ (gnugo--ERR-wait
+ color (if suggestion
+ "Still thinking"
+ "Not your turn yet"))))
(gnugo--gate-game-over in-progress-p))
(defun gnugo-sentinel (proc string)
- [elpa] externals/gnugo 6c7e102 181/357: [gnugo int] Rename :waitingp to :waiting; save color there., (continued)
- [elpa] externals/gnugo 6c7e102 181/357: [gnugo int] Rename :waitingp to :waiting; save color there., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 425731b 196/357: [gnugo int] Add abstraction: gnugo--ERR-wait, Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 3f3af4b 208/357: [gnugo int] Remove from ‘gnugo-state’ instead of setting to nil., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo f28d241 223/357: [gnugo int] Decruft: Don't set provisional :last-user-bpos., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 8211cb9 224/357: [gnugo int] Couple :center-position and :SZ jamming., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 536960c 230/357: [gnugo int] Fix bug: On -l/--infile, inhibit first move if game over., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 50cc2b3 233/357: [gnugo int] Add abstraction: gnugo--q/ue, Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 3903907 235/357: [gnugo] Validate position arg of GTP commands ‘undo’, ‘gg-undo’., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo ab1f4c2 242/357: [gnugo] Fix bug: DTRT for suggestion ‘nowarp’ check., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo e814724 243/357: [gnugo] Allow user to request suggestion for GNU Go., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 5157534 241/357: [gnugo int] Use ‘destructuring-bind’ more.,
Stefan Monnier <=
- [elpa] externals/gnugo 6c99d78 251/357: [gnugo int] Add abstraction: gnugo--no-worries, Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 9f5fcfc 250/357: [gnugo int] Add abstraction: gnugo--resignp, Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 2612c6b 263/357: [gnugo] Replace abdication w/ Assist and Zombie minor modes., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo b586e0c 268/357: [gnugo] Refuse to climb towards root when in Assist mode., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo af7aa4a 267/357: [gnugo] Fix bug: On role switch, flip karma after roles., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo b6ac4ac 283/357: [gnugo frolic] Add command to navigate to end of branch., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 5414994 277/357: [gnugo] Handle function for ‘gnugo-xpms’ value., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo f42837f 280/357: [gnugo int] Mention ‘gnugo-frolic-mode-map’ in Commentary; nfc., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo ef2bfa7 273/357: [gnugo maint] Update HACKING; nfc., Stefan Monnier, 2020/11/29
- [elpa] externals/gnugo 407ca43 266/357: [gnugo int] Move some ‘gnugo-gate’ calls down-chain., Stefan Monnier, 2020/11/29